diff --git a/language/predefined/variables/argc.xml b/language/predefined/variables/argc.xml index 7e0acab0da..c3849023d5 100644 --- a/language/predefined/variables/argc.xml +++ b/language/predefined/variables/argc.xml @@ -1,5 +1,5 @@ - + @@ -15,13 +15,14 @@ - The script's filename is always passed as an argument to the script. + The script's filename is always passed as an argument to the script, therefore + the minimum value of $argc is 1. This variable is only available when register_argc_argv - is enabled in php.ini. + is enabled. diff --git a/language/predefined/variables/argv.xml b/language/predefined/variables/argv.xml index 696f4dd0e1..80cd1be9a2 100644 --- a/language/predefined/variables/argv.xml +++ b/language/predefined/variables/argv.xml @@ -1,5 +1,5 @@ - + @@ -15,13 +15,14 @@ - The first argument is always the current script's filename. + The first argument is always the current script's filename, therefore + $argv[0] is the script's name. This variable is only available when register_argc_argv - is enabled in php.ini. + is enabled. diff --git a/language/predefined/variables/cookie.xml b/language/predefined/variables/cookie.xml index b7023aec13..498ff3045e 100644 --- a/language/predefined/variables/cookie.xml +++ b/language/predefined/variables/cookie.xml @@ -1,10 +1,10 @@ - + $_COOKIE - $HTTP_COOKIE_VARS + $HTTP_COOKIE_VARS [deprecated] HTTP Cookies @@ -17,22 +17,11 @@ $HTTP_COOKIE_VARS contains the same initial - information, but is not a superglobal. (Note that - $HTTP_COOKIE_VARS and $_COOKIE + information, but is not a superglobal. + (Note that $HTTP_COOKIE_VARS and $_COOKIE are different variables and that PHP handles them as such) - - If the register_globals directive - is set, then these variables will also be made available in the - global scope of the script; i.e., separate from the - $_COOKIE and $HTTP_COOKIE_VARS - arrays. For related information, see the security chapter titled - Using Register Globals. - These individual globals are not superglobals. - - @@ -51,9 +40,8 @@ 4.1.0 - Introduced $_COOKIE. - Note that the deprecated $HTTP_COOKIE_VARS - did exist previously. + Introduced $_COOKIE that deprecated + $HTTP_COOKIE_VARS. @@ -96,8 +84,9 @@ Hello Hannes! &reftitle.seealso; - setcookie + setcookie Handling external variables + The filter extension diff --git a/language/predefined/variables/env.xml b/language/predefined/variables/env.xml index 34dc5d8272..7a6b133ca8 100644 --- a/language/predefined/variables/env.xml +++ b/language/predefined/variables/env.xml @@ -1,10 +1,10 @@ - + $_ENV - $HTTP_ENV_VARS + $HTTP_ENV_VARS [deprecated] Environment variables @@ -32,22 +32,11 @@ $HTTP_ENV_VARS contains the same initial - information, but is not a superglobal. (Note that - $HTTP_ENV_VARS and $_ENV + information, but is not a superglobal. + (Note that $HTTP_ENV_VARS and $_ENV are different variables and that PHP handles them as such) - - If the register_globals directive - is set, then these variables will also be made available in the - global scope of the script; i.e., separate from the - $_ENV and $HTTP_ENV_VARS - arrays. For related information, see the security chapter titled - Using Register Globals. - These individual globals are not superglobals. - - @@ -66,9 +55,8 @@ 4.1.0 - Introduced $_ENV. - Note that the deprecated $HTTP_ENV_VARS - did exist previously. + Introduced $_ENV that deprecated + $HTTP_ENV_VARS. @@ -112,6 +100,7 @@ My username is bjori! getenv + The filter extension diff --git a/language/predefined/variables/files.xml b/language/predefined/variables/files.xml index b8a2ec64ba..f3442b2ebe 100644 --- a/language/predefined/variables/files.xml +++ b/language/predefined/variables/files.xml @@ -1,10 +1,10 @@ - + $_FILES - $HTTP_POST_FILES + $HTTP_POST_FILES [deprecated] HTTP File Upload variables @@ -17,22 +17,11 @@ $HTTP_POST_FILES contains the same initial - information, but is not a superglobal. (Note that - $HTTP_POST_FILES and $_FILES + information, but is not a superglobal. + (Note that $HTTP_POST_FILES and $_FILES are different variables and that PHP handles them as such) - - If the register_globals directive - is set, then these variables will also be made available in the - global scope of the script; i.e., separate from the - $_FILES and $HTTP_POST_FILES - arrays. For related information, see the security chapter titled - Using Register Globals. - These individual globals are not superglobals. - - @@ -51,9 +40,8 @@ 4.1.0 - Introduced $_FILES. - Note that the deprecated $HTTP_POST_FILES - did exist previously. + Introduced $_FILES that deprecated + $HTTP_POST_FILES. diff --git a/language/predefined/variables/get.xml b/language/predefined/variables/get.xml index 4bc56311e2..a7465cd5f8 100644 --- a/language/predefined/variables/get.xml +++ b/language/predefined/variables/get.xml @@ -1,10 +1,10 @@ - + $_GET - $HTTP_GET_VARS + $HTTP_GET_VARS [deprecated] HTTP GET variables @@ -17,22 +17,11 @@ $HTTP_GET_VARS contains the same initial - information, but is not a superglobal. (Note that - $HTTP_GET_VARS and $_GET + information, but is not a superglobal. + (Note that $HTTP_GET_VARS and $_GET are different variables and that PHP handles them as such) - - If the register_globals directive - is set, then these variables will also be made available in the - global scope of the script; i.e., separate from the - $_GET and $HTTP_GET_VARS - arrays. For related information, see the security chapter titled - Using Register Globals. - These individual globals are not superglobals. - - @@ -51,9 +40,8 @@ 4.1.0 - Introduced $_GET. - Note that the deprecated $HTTP_GET_VARS - did exist previously. + Introduced $_GET that deprecated + $HTTP_GET_VARS. @@ -97,6 +85,7 @@ Hello Hannes! Handling external variables + The filter extension diff --git a/language/predefined/variables/globals.xml b/language/predefined/variables/globals.xml index 87ea953e72..83a181ea14 100644 --- a/language/predefined/variables/globals.xml +++ b/language/predefined/variables/globals.xml @@ -1,7 +1,7 @@ - + - + $GLOBALS References all variables available in global scope @@ -10,7 +10,7 @@ &reftitle.description; - An associative array containing references to all variables which + An associative array containing references to all variables which are currently defined in the global scope of the script. The variable names are the keys of the array. @@ -50,6 +50,13 @@ $foo in current scope: local variable &reftitle.notes; ¬e.is-superglobal; + + Variable availability + + Unlike all of the other superglobals, + $GLOBALS has essentially always been available in PHP. + + diff --git a/language/predefined/variables/post.xml b/language/predefined/variables/post.xml index bba5cf921f..48df56b859 100644 --- a/language/predefined/variables/post.xml +++ b/language/predefined/variables/post.xml @@ -1,10 +1,10 @@ - + $_POST - $HTTP_POST_VARS + $HTTP_POST_VARS [deprecated] HTTP POST variables @@ -17,22 +17,11 @@ $HTTP_POST_VARS contains the same initial - information, but is not a superglobal. (Note that - $HTTP_POST_VARS and $_POST + information, but is not a superglobal. + (Note that $HTTP_POST_VARS and $_POST are different variables and that PHP handles them as such) - - If the register_globals directive - is set, then these variables will also be made available in the - global scope of the script; i.e., separate from the - $_POST and $HTTP_POST_VARS - arrays. For related information, see the security chapter titled - Using Register Globals. - These individual globals are not superglobals. - - @@ -51,9 +40,8 @@ 4.1.0 - Introduced $_POST. - Note that the deprecated $HTTP_POST_VARS - did exist previously. + Introduced $_POST that deprecated + $HTTP_POST_VARS. @@ -97,6 +85,7 @@ Hello Hannes! Handling external variables + The filter extension diff --git a/language/predefined/variables/request.xml b/language/predefined/variables/request.xml index 11f9802b22..337215f5db 100644 --- a/language/predefined/variables/request.xml +++ b/language/predefined/variables/request.xml @@ -1,47 +1,20 @@ - + $_REQUEST - Request variables + HTTP Request variables &reftitle.description; - An associative array consisting of the contents of - $_GET, $_POST, - and $_COOKIE. + An associative array that by default contains the contents of + $_GET, + $_POST&listendand; + $_COOKIE. - - - Variables provided to the script via the GET, POST, and COOKIE input - mechanisms, and which therefore cannot be trusted. The presence and - order of variable inclusion in this array is defined according to the - PHP variables_order - configuration directive. This array has no direct analogue in versions - of PHP prior to 4.1.0. - - - - When running on the command line - , this will not include the - argv and argc entries; these are - present in the $_SERVER array. - - - - If the register_globals directive - is set, then these variables will also be made available in the - global scope of the script; i.e., separate from the - $_REQUEST array. For related information, see - the security chapter titled Using Register - Globals. These individual globals are not superglobals. - - @@ -57,11 +30,18 @@ + + 5.3.0 + + Introduced request_order. + This directive affects the contents of $_REQUEST. + + 4.3.0 - $_FILES information was removed from - $_REQUEST. + $_FILES information + was removed from $_REQUEST. @@ -79,6 +59,25 @@ &reftitle.notes; ¬e.is-superglobal; + + + When running on the command line + , this will not include the + argv and + argc entries; these are + present in the $_SERVER + array. + + + + + Variables provided to the script via the GET, POST, and COOKIE input + mechanisms, and which therefore cannot be trusted. The presence and + order of variable inclusion in this array is defined according to the + PHP variables_order + configuration directive. + + @@ -86,6 +85,7 @@ import_request_variables Handling external variables + The filter extension diff --git a/language/predefined/variables/server.xml b/language/predefined/variables/server.xml index 2e50213546..13f034386a 100644 --- a/language/predefined/variables/server.xml +++ b/language/predefined/variables/server.xml @@ -1,11 +1,11 @@ - + $_SERVER - $HTTP_SERVER_VARS - Server and execution enviroment information + $HTTP_SERVER_VARS [deprecated] + Server and execution environment information @@ -23,26 +23,16 @@ $HTTP_SERVER_VARS contains the same initial - information, but is not a superglobal. (Note that - $HTTP_SERVER_VARS and $_SERVER + information, but is not a superglobal. + (Note that $HTTP_SERVER_VARS and $_SERVER are different variables and that PHP handles them as such) - - If the register_globals directive - is set, then these variables will also be made available in the - global scope of the script; i.e., separate from the - $_SERVER and $HTTP_SERVER_VARS - arrays. For related information, see the security chapter titled - Using Register Globals. - These individual globals are not superglobals. - - You may or may not find any of the following elements in - $_SERVER. Note that few, if any, of these will be available (or - indeed have any meaning) if running PHP on the command line. + $_SERVER. Note that few, if any, of these will be + available (or indeed have any meaning) if running PHP on the + command line. @@ -68,7 +58,7 @@ - 'argv' + '$argv' Array of arguments passed to the script. When the script is @@ -80,7 +70,7 @@ - 'argc' + '$argc' Contains the number of command line parameters passed to the @@ -497,9 +487,8 @@ 4.1.0 - Introduced $_SERVER. - Note that the deprecated $HTTP_SERVER_VARS - did exist previously. + Introduced $_SERVER that the deprecated + $HTTP_SERVER_VARS. @@ -534,7 +523,16 @@ www.example.com &reftitle.notes; ¬e.is-superglobal; - + + + &reftitle.seealso; + + + The filter extension + + + + + $_SESSION - $HTTP_SESSION_VARS + $HTTP_SESSION_VARS [deprecated] Session variables @@ -19,25 +19,12 @@ $HTTP_SESSION_VARS contains the same initial - information, but is not a superglobal. (Note that - $HTTP_SESSION_VARS and $_SESSION + information, but is not a superglobal. + (Note that $HTTP_SESSION_VARS and $_SESSION are different variables and that PHP handles them as such) - - - If the register_globals directive - is set, then these variables will also be made available in the - global scope of the script; i.e., separate from the - $_SESSION and $HTTP_SESSION_VARS - arrays. For related information, see the security chapter titled - Using Register Globals. - These individual globals are not superglobals. - - - &reftitle.changelog; @@ -53,9 +40,8 @@ 4.1.0 - Introduced $_SESSION. - Note that the deprecated $HTTP_SESSION_VARS - did exist previously. + Introduced $_SESSION that the deprecated + $HTTP_SESSION_VARS. @@ -69,6 +55,15 @@ ¬e.is-superglobal; + + &reftitle.seealso; + + + session_start + + + +