php strlen() function
Translation results:
English [leŋθ] American [leŋθ]
n.Length, long; length of time; (speech) sound length; paragraph, section
Plural: lengths
php strlen() functionsyntax
Function: Return the length of the string
Syntax: strlen(string)
Parameters:
Parameters | Description |
string | Required. Specifies the string to check. |
Description: Returns the length of the string.
php strlen() functionexample
<?php echo strlen("I love php!"); ?>
Run Instance»
Click the "Run Instance" button to view the online instance
Output:
11
<?php echo strlen("i study php at php.cn"); ?>
Run Instance»
Click the "Run Instance" button to view the online instance
Output:
21