public static function lower($string, $locale = false, $charset = null)
    {
        if ($locale) {
            if (Horde_Util::extensionExists('mbstring')) {
                if (is_null($charset)) {
                    throw new InvalidArgumentException('$charset argument must not be null');
                }
                $ret = @mb_strtolower($string, self::_mbstringCharset($charset));
                if (!empty($ret)) {
                    return $ret;
                }
            }
            return strtolower($string);
        }

        if (!isset(self::$_lowers[$string])) {
            $language = setlocale(LC_CTYPE, 0);
            setlocale(LC_CTYPE, 'C');
            self::$_lowers[$string] = strtolower($string);
            setlocale(LC_CTYPE, $language);
        }

        return self::$_lowers[$string];
    }
public static function lower($string, $locale = false, $charset = null)
    {
        if ($locale) {
            if (Horde_Util::extensionExists('mbstring')) {
                if (is_null($charset)) {
                    throw new InvalidArgumentException('$charset argument must not be null');
                }
                $ret = @mb_strtolower($string, self::_mbstringCharset($charset));
                if (!empty($ret)) {
                    return $ret;
                }
            }
            return strtolower($string);
        }

        if (!isset(self::$_lowers[$string])) {
            $language = setlocale(LC_CTYPE, 0);
            setlocale(LC_CTYPE, 'C');
            self::$_lowers[$string] = strtolower($string);
            setlocale(LC_CTYPE, $language);
        }

        return self::$_lowers[$string];
    }
public static function lower ( $ string , $ locale = false , $ charset = null ) { if ( $ locale ) { if ( Horde_Util :: extensionExists ( 'mbstring' ) ) { if ( is_null ( $ charset ) ) { throw new InvalidArgumentException ( '$charset argument must not be null' ) ; } $ ret = @ mb_strtolower ( $ string , self :: _mbstringCharset ( $ charset ) ) ; if ( ! empty ( $ ret ) ) { return $ ret ; } } return strtolower ( $ string ) ; } if ( ! isset ( self :: $ _lowers [ $ string ] ) ) { $ language = setlocale ( LC_CTYPE , 0 ) ; setlocale ( LC_CTYPE , 'C' ) ; self :: $ _lowers [ $ string ] = strtolower ( $ string ) ; setlocale ( LC_CTYPE , $ language ) ; } return self :: $ _lowers [ $ string ] ; }
Makes a string lowercase.

@param string $string   The string to be converted.
@param boolean $locale  If true the string will be converted based on
a given charset, locale independent else.
@param string $charset  If $locale is true, the charset to use when
converting.

@return string  The string with lowercase characters.
Makes a string lowercase .