Strlen () is commonly used in loops and other functions when it is important to determine when a string ends. (for example, in a loop, we might need to stop looping after the last character of the string).
The Strpos () function is used to retrieve the specified character or text within a string.
If a match is found, the first matching character position is returned . If no match is found, FALSE is returned.
For a value definition
Set PHP Constants
To set a constant, use the Define () function-it uses three parameters:
- The first parameter defines the name of the constant
- The second parameter defines the value of a constant
- The optional third parameter specifies whether the constant name is case insensitive. The default is False.
。
PHP operators
x = y |
x = y |
The right-hand expression sets the value for the left operand. |
x + = y |
x = x + y |
Add |
X-= y |
x = XY |
Reducing |
X *= y |
x = x * y |
By |
X/= y |
× = x/y |
Except |
X%= y |
x = x% y |
Modulus |
Talking about PHP