Home > Backend Development > PHP Tutorial > About php super global variable array

About php super global variable array

WBOY
Release: 2016-07-25 09:08:14
Original
833 people have browsed it
PHP super global variable array (Super Global Array), also known as PHP predefined array, is built into the PHP engine and does not need to be redefined by developers.

Introduction: PHP super global variable array (Super Global Array), also known as PHP predefined array, is built into the PHP engine and does not need to be redefined by developers. When the php script is running, PHP will automatically put some data in the super global array.

php super global variable $_GET[] Get the variable array submitted with the GET method $_POST[] Gets the array of variables submitted with the POST method $_COOKIE[] Gets and sets the cookie identifier of the current website $_SESSION[] obtains the unique identifier of the current user's access, expressed in the form of an array, such as sessionid and custom session data $_ENV[] Current php environment variable array $_SERVER[] Current php server variable array $_FILES[] Parameter values ​​submitted to the current script when uploading files, expressed in the form of an array $_REQUEST[] contains all requests submitted by the current script, All actions of $_GET, $_POST, $_COOKIE, $_SESSION $GLOBALS[] contains references to all super global variables of the executing script

php system constants __FILE__ The absolute path and file name of the current PHP program script __LINE__ stores the line number where the constant is located __FUNCTION__ The name of the function where the constant is stored __CLASS__ is the name of the class in which the constant is stored. __METHOD__ stores the name of the method in the class where the constant is located PHP_VERSION stores the current PHP version number, which can also be obtained through the PHPVERSION() function. PHP_OS stores the operating system of the current server



source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template