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 only be used in double quotes.
Variable
You must add "$" before the variable. You do not need to specify (or define) The type of the variable before using the variable. You can assign values to the same variable for different types of data. However, to use a global variable, use the global description (or add it to the $ GLOBALS [] array ). Static variables must be used.
Array
You can use an array directly without specifying its type and size. Each element of the same array can have different data types.
Operator
Generally, operators in the C language are retained. Added the string connector "." (used to access object members "-> "). Added the "=>" operator to assign initial values to the array. In addition, logic and ("&") and logic or ("|") are also available "and" and "or", adding logical differences or "xor"
Basic statement
Master the if-else statements, switch-case statements, for statements, while statements, do-while statements, continue statements, and break statements. The require and include statements are used to insert a disk file.
Function Definition and usage
You do not need to specify the function type and parameter type when using the function to define a function.
Function Name (parameter 1, parameter 2 ,......)
{Statement 1;
Statement 2 ;......
}
From the bing7599069 Column