PHP extension options and configuration information. these functions allow you to obtain many PHP parameters, such as runtime configurations, loaded extensions, and versions. You will also find the function that sets the PHP option in your running
PHP extension-output buffer control
Introduction
When PHP scripts have output, the output control function can use these to control the output. This is useful in many different situations, especially when the script starts to output data, it sends
The garbage collection mechanism of PHP features-Factors to be considered in performance may affect the performance slightly, but it is only available when comparing PHP 5.2 with PHP 5.3. Although in PHP 5.2, the root of the record may be slower
Php array learning array: a set of keywords and values. The same php array can store multiple values of different data types. the array subscript can be used to create an array from scratch: (1) $ arr [0] 1; array element $ arr [1] 2.8 ;...... (2) $
PHP features permanent database connection refers to the connection that is not closed when the script ends running. When receiving a permanent connection request. PHP will check whether there is already a permanent connection (previously enabled.
PHP features using remote HTTP file and FTP file operations only in php. if the allow_url_fopen option is activated in the ini file, HTTP and FTP URLs can be used in most functions that require file names as parameters to replace file names. You can
Split into thousands of parts for sorting and merging. First, create a txt file with 0.1 billion QQ numbers. PHPcode split into thousands of parts for sorting and merging.
First, create a txt file with 0.1 billion QQ numbers.
PHP code?
//
PHP features-session mechanism-the use of cookies in PHP transparently supports HTTP cookies. Cookie is a mechanism for storing data in a remote browser and tracking and identifying users. You can use the setcookie () or setrawcookie () function to
PHP features: the HTTP authentication mechanism of PHP for HTTP authentication is only valid when PHP runs in Apache module mode. Therefore, this function is not applicable to CGI versions. In the PHP script of the Apache module, you can use the
Php lottery probability algorithm
/** The lottery drawing principle with different probabilities is to divide the 0 to * (total proportion) intervals based on the proportion of the entire item, then, the random number seed is used to generate a
PHP Security error reports are a double-edged sword for PHP Security. On the one hand, it can improve security and on the other hand, it is harmful.
The common method used to attack the system is to input incorrect data and view the error message
PHP-based protocols and encapsulation protocols supported by PHP include many built-in URL-style encapsulation protocols, which can be used for encapsulation such as fopen (), copy (), file_exists (), and filesize () file system functions. In
PHP Basics pre-defined exceptions
1. Exception
(PHP 5> = 5.1.0)
Introduction
Exception is the base class of all exceptions.
Method
Exception: :__ construct-Exception constructor
Exception: getMessage-get Exception message content
Exception:
PHP has predefined 9 Super global variables, 8 Magic variables, and 13 magic methods during design. these variables and functions can be used anywhere in the script without being declared. These variables and functions are frequently used in PHP
PHP-based reference explanation-reference transfer and return reference transfer
A variable can be passed to the function through reference, so that the function can modify the value of its parameter. Syntax:
Note that there is no reference
Require () and require_once (): the same file is called only once and is usually placed at the beginning of the PHP program. before the PHP program is executed, read the file specified by require first. If an error occurs, it is fatal. Include ()
& Amp; lt ;? Php * array traversal ** 1. use the for statement to traverse the array cyclically *. other languages (only this method) * B. in PHP, this method is not our preferred method * c. the array must be an index array, and the subscript must
For general anti-injection, you only need to use the php addslashes function. $ _ POSTsql_injection ($ _ POST); $ _ GETsql_injection ($ _ GET); functionsql_injection ($ content) {if (! Get_magic_quotes_gpc () {if (I... general anti-injection, you
Php Chinese network (www.php.cn) provides the most comprehensive basic tutorial on programming technology, introducing HTML, CSS, Javascript, Python, Java, Ruby, C, PHP, basic knowledge of MySQL and other programming languages. At the same time,
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service