Introduction to PHP predefined variables

小云云
Release: 2023-03-22 12:24:01
Original
1593 people have browsed it

What are the predefined variables in php? This article mainly shares with you an introduction to PHP predefined variables, hoping to help you.

1. Predefined variables are not user-defined variables, but variables defined by PHP. Users can use them directly. There are 9 commonly used predefined variables

1. $_GET( ): Receive data transmitted by GET method

2. $_POST(): Receive data transmitted by POST method

3. $_REQUEST(): Receive data transmitted by any method

4. $_SERVER: Server and client related information

5. $GLOBALS: Global data

6. $_COOKIE: Cookie stores data to the user’s computer

7. $_SESSION: session stores user data on the server and can be used across files

8. $_FILES: file upload

9. $_ENV: environment variable

The above 9 predefined variables all encapsulate different data.

Related recommendations:

Detailed explanation of PHP predefined variables

Detailed explanation of PHP predefined variable examplesphp predefined variable

The above is the detailed content of Introduction to PHP predefined variables. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
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
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!