| @@ -11,8 +11,12 @@ | ||
| 11 | 11 | '4' => 30, '5' => 31, '6' => 32, '7' => 33, '8' => 34, '9' => 35, |
| 12 | 12 | ); |
| 13 | 13 | public static function idn_to_utf8($domain) |
| 14 | 14 | { |
| 15 | + //if mb-string not installed | |
| 16 | + if (!function_exists('mb_strtolower')) { | |
| 17 | + return $domain; | |
| 18 | + } | |
| 15 | 19 | $domain = mb_strtolower($domain); |
| 16 | 20 | $parts = explode('.', $domain); |
| 17 | 21 | foreach ($parts as &$part) { |
| 18 | 22 | $length = \strlen($part); |