/* Predefined array:
* Automatic Global variables --- super global array
*
* 1. Contains data from WEB server, client, running environment and user input
* 2. These arrays are special
* 3. It takes effect automatically in the global scope, and you can use these arrays directly
* 4. Users cannot customize these arrays, but the operation methods of these arrays are the same as those defined by themselves
* 5. Directly in the function You can use these arrays
*
* $_GET //Variables submitted to the script via URL request
* $_POST //Variables submitted to the script via the HTTP POST method
* $_REQUEST //Via Variables submitted to the script by GET, POST and COOKIE mechanisms
* $_FILES //Variables submitted to the script via http post method file upload
* $_COOKIE
* $_SESSION
* $_ENV / /Variables submitted by the execution environment to the script
* $_SERVER //Variables are set by the WEB server, or directly associated with the execution environment of the current script
* $GLOBALS //As long as the variables are valid for the current script Here, the key name of the array is the name of the global script
*
*
*/
//The super global array can be called directly inside the function
$arr=array(10,20 );//General array
$_GET=array(50,90);//Super global array
function demo(){
global $arr;//When calling global variables, you must first include
print_r($arr);
print_r($_GET); // Directly call the super global array without including
}
?>
//Use the passed value directly as a variable, as php. Useful when register_global=on in ini configuration file.
echo $username."
";
echo $email."
";
echo $page."
";
//The most stable Value method
echo $_GET["username"]."
";
echo $_GET["email"]."
";
echo $_GET["page "]."
";
?>
this is a $_GET test< /a>