You are here : phpstringstrlen

strlen() - string

Returns the length of the given string.
Parameters :
  • string - The string being measured for length.

  • Syntax

    int strlen
        ( string $string
       )


    Example

    <?php$str = 'abcdef';echo strlen($str); // 6$str = ' ab cd ';echo strlen($str); // 7?>


    Output / Return Value


    Limitations


    Alternatives / See Also


    Reference