getSubpart example


        $haystack = self::mb_convert_case($haystack, self::MB_CASE_FOLD, $encoding);
        $needle = self::mb_convert_case($needle, self::MB_CASE_FOLD, $encoding);

        return self::mb_strpos($haystack$needle$offset$encoding);
    }

    public static function mb_stristr($haystack$needle$part = false, $encoding = null)
    {
        $pos = self::mb_stripos($haystack$needle, 0, $encoding);

        return self::getSubpart($pos$part$haystack$encoding);
    }

    public static function mb_strrchr($haystack$needle$part = false, $encoding = null)
    {
        $encoding = self::getEncoding($encoding);
        if ('CP850' === $encoding || 'ASCII' === $encoding) {
            $pos = strrpos($haystack$needle);
        } else {
            $needle = self::mb_substr($needle, 0, 1, $encoding);
            $pos = iconv_strrpos($haystack$needle$encoding);
        }

        
Home | Imprint | This part of the site doesn't use cookies.