When PHP accepts information submitted through an HTML form, it saves the submitted data in a global array, and we can call the system-specific array of automatic global variables to get those values. The usual automatic global variables are as follows:
In getting form data, the most common automatic global variables are $_get and $_post, which obtain data submitted through the Get method and submitted via the POST method, respectively. For example, a text box form control called "User", if submitted with the Get method, can be used
$_get["user"] or $_get[' user '
Instance Code
register.php:
request.php
<?php $username = $_post[' username '); $name = $_post[' name ']; $pwd = $_post[' pwd ']; $email = $_post[' email ']; Print_r ($username); if (!empty ($username)) {echo "Your information is: <br>\n"; echo "username: $username <br>\n"; echo "Name: $name <br>\n"; EC Ho "Password: $pwd <br>\n"; echo "Email: $email <br>\n"; } print_r ($_post)//echo "AAAA";?> </PRE> </p>