latin1 if( '' === $from_encoding || 'ISO-8859-1' === $from_encoding || 'cp1252' === $from_encoding ){ if( '' === $to_encoding || 'UTF-8' === $to_encoding || 'US-ASCII' === $to_encoding ){ if( function_exists('loco_fix_utf8') ) { return loco_fix_utf8( $str ); } } } trigger_error('Unable to convert from '.$from_encoding.' to '.$to_encoding.' without mbstring', E_USER_NOTICE ); } return $str; } } // @codeCoverageIgnoreStart if( ! function_exists('mb_detect_encoding') ){ function mb_detect_encoding( $str = '', array $encoding_list = array(), $strict = false ){ return Loco_compat_MbstringExtension::mb_detect_encoding( $str, $encoding_list, $strict ); } } if( ! function_exists('mb_list_encodings') ){ function mb_list_encodings(){ return Loco_compat_MbstringExtension::mb_list_encodings(); } } if( ! function_exists('mb_strlen') ){ function mb_strlen( $str, $encoding = null ){ return Loco_compat_MbstringExtension::mb_strlen( $str, $encoding ); } } if( ! function_exists('mb_convert_encoding') ){ function mb_convert_encoding( $str, $to_encoding, $from_encoding = null ){ return Loco_compat_MbstringExtension::mb_convert_encoding( $str, $to_encoding, $from_encoding ); } } if( ! function_exists('mb_encoding_aliases') ){ function mb_encoding_aliases(){ return false; } }