Conditions | 3 |
Paths | 3 |
Total Lines | 10 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
19 | public static function convertEncoding($string, $code = 'UTF-8', $to = 'auto') |
||
20 | { |
||
21 | if (is_array($string)) { |
||
22 | $strings = []; |
||
23 | foreach ($string as $key => $value) { |
||
24 | $strings[$key] = mb_convert_encoding($value, $code, $to); |
||
25 | } |
||
26 | return $strings; |
||
27 | } |
||
28 | return mb_convert_encoding($string, $code, $to); |
||
29 | } |
||
31 |