WordPress at Your Fingertips
function is not described

ParagonIE_Sodium_Core_Util::strlen() public WP 1.0

Safe string length

{} It's a method of the class: ParagonIE_Sodium_Core_Util{}

No Hooks.

Return

Int.

Usage

$result = ParagonIE_Sodium_Core_Util::strlen( $str );
$str(string) (required)
-

Code of ParagonIE_Sodium_Core_Util::strlen() WP 5.8.3

public static function strlen($str)
{
    /* Type checks: */
    if (!is_string($str)) {
        throw new TypeError('String expected');
    }

    return (int) (
    self::isMbStringOverride()
        ? mb_strlen($str, '8bit')
        : strlen($str)
    );
}