This note only extracts the notes for php, and does not write any content about operators or simple judgments.
1 string
1.1 strlen () function compute String Length
The 1.2 strops () function searches strings or characters in strings.
2 array
2.1
After PHP5.0, php provides more object-oriented methods to make php more powerful !!Some functions called magic methods in PHP are introduced here: in fact, they are used in common applications !!1. _ construct () when instantiating an object, this
(1) _ construct () is a built-in PHP constructor that is automatically called by the PHP parsing engine. when an object is instantiated, this method of this object is called first.
Example: class Test
{
Function _ construct ()
{
Echo "This is _
Upload the rar package in php and decompress it to the directory.
1. Principles of php Upload and decompression
Normal upload function upload Server
Rar
The system component is loaded by zip and decompressed to the directory.
7z
2.
Void header (string [, bool replace [, int http_response_code])Void header (string [, bool replace [, int http_response_code])
Header () is used to send HTTP headers. Replace is an optional parameter, indicating whether to replace a similar header
The newly configured PHP environment or configuration changes have just been made, such as the newly loaded DLL extension and webpage access, may cause "invalid memory location access ." . The main reason is that the DLL extension fails to load.
We
1. configuration files involved:/Etc/php5/apache2/php. ini2. Specific rows:Display_errors =Error_reporting =3. Remember to restart the service.
PHP Error ReportThe php. ini file contains many configuration settings. You should have set your php. ini
In most cases, we need to connect several strings and display them. In PHP, strings are connected by "points", that is, periods in English. ". The usage is as follows:
// Define a string
$ Str1 = "Hello World! ";
$ Str2 = "Welcome to huaow's
Character flip is a piece of cake for php processing. php's string function strrev can handle the following:
Echo strrev ("Hello World! "); // The output result is "! DlroW olleH"
However, sometimes during interviews, we often need to write a
This is something I accidentally saw today. I first came into contact with jquery and wrote it as an unexpected result for me. It's just a beginner's understanding...
Start writing this verification from understanding jquery...
In most cases,
The PHP stdClass () is something that isn' t well known ented but I will try to shed some light into the matter. stdClass is a default PHP object which has no predefined members. the name stdClass is used internally by Zend and is reserved. so
In the previous project development process, a calendar month and a calendar week were required. Because there was too little project experience at that time, the formatted time was saved to the database during the storage time, it also determines
1. sys_getloadavg () function
Sys_getloadavt () can obtain the system load. This function returns an array containing three elements, each representing the average load of the system in the past 1, 5, and 15 minutes.
Instead of letting the
I recently used PHP for development and was not very depressed about debugging. I found an article on the Internet to set up the environment. Some of the articles are outdated, and many of them are not mentioned, it is difficult for cainiao like
This is the html code. This is mainly used for PHP to download the content of this site. It puts the files to be downloaded and the PHP code page in the same directory, hoping to help more people, if you have any questions, contact QQ: 523132661
Data Type
PHP only has three basic data types: integer, floating-point number (or real number, double-precision number), and string. Strings can be enclosed in single quotes and double quotes, but they have different meanings: variables can
Note: add the public page to session_start ();
Session_start ();
Ini_set ('display _ errors ', 'off ');
Class CCheckCodeFile
{
// Number of digits of the Verification Code www.2cto.com
Var $ mCheckCodeNum = 4;
// Generated Verification Code
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