Top Banner
PHP Chapter 19: PHP By: Eyad Alshareef Eyad Alshareef
13

Chapter 19 Eyad-D

Sep 30, 2015

Download

Documents

Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript

PHP

PHPChapter 19: PHPBy: Eyad AlshareefEyad Alshareef

Eyad Alshareef

219.8 Form Processing and Business LogicSuperglobal arrays are associative arrays predefined by PHP that hold variables acquired from user input, the environment or the web server and are accessible in any variable scope.The arrays $_GET and $_POST retrieve information sent to the server by HTTP get and post requests, respectively.Eyad Alshareef3

Eyad AlshareefForm processingaction propertyWhere to send form data (php file)method propertyPostGetEach element has unique name

Eyad Alshareef19.8.2 Using PHP to Process HTML5 FormsUsing method = "post" appends form data to the browser request that contains the protocol and the requested resources URL. Scripts located on the web servers machine can access the form data sent as part of the request.Eyad Alshareef619.4 Form Processing and Business Logic (Cont.)We escape the normal meaning of a character in a string by preceding it with the backslash character (\).Function die terminates script execution. The functions optional argument is a string, which is printed as the script exits. Eyad Alshareef7

Eyad Alshareef

Eyad Alshareef

Eyad Alshareef

Eyad Alshareef

Eyad Alshareef

Eyad Alshareef