Conditions | 4 |
Paths | 4 |
Total Lines | 16 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
38 | public function process($value, $preserve_keys = false) |
||
39 | { |
||
40 | if (is_array($value)) { |
||
41 | return array_reverse($value, $preserve_keys); |
||
42 | } elseif (($charset = $this->core->getCharset()) === 'iso-8859-1') { |
||
43 | return strrev((string)$value); |
||
44 | } |
||
45 | |||
46 | $strlen = mb_strlen($value); |
||
47 | $out = ''; |
||
48 | while ($strlen --) { |
||
49 | $out .= mb_substr($value, $strlen, 1, $charset); |
||
50 | } |
||
51 | |||
52 | return $out; |
||
53 | } |
||
54 | } |