From 8a8104b258a296c2710caf2911b87403c9ef3d97 Mon Sep 17 00:00:00 2001 From: SC Yoo Date: Fri, 20 Feb 2015 12:14:07 +0900 Subject: Added class-exitsts --- inc/utf8.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'inc/utf8.php') diff --git a/inc/utf8.php b/inc/utf8.php index c6a189490..2b6a0c498 100644 --- a/inc/utf8.php +++ b/inc/utf8.php @@ -356,8 +356,12 @@ if(!function_exists('utf8_strtolower')){ * @return string */ function utf8_strtolower($string){ - if(UTF8_MBSTRING) return normalizer::normalize(mb_strtolower($string,'utf-8')); - + if(UTF8_MBSTRING) { + if (class_exists("Normalizer", $autoload = false)) + return normalizer::normalize(mb_strtolower($string,'utf-8')); + else + return (mb_strtolower($string,'utf-8')); + } global $UTF8_UPPER_TO_LOWER; return strtr($string,$UTF8_UPPER_TO_LOWER); } -- cgit v1.2.3