move mb_strlen call out of for loop definition

This commit is contained in:
Zach Prezkuta 2013-02-04 20:17:56 -07:00
parent 9dbe7efce5
commit b6bc7daadf

View file

@ -175,7 +175,8 @@ if(! function_exists('xmlify')) {
function xmlify($str) { function xmlify($str) {
$buffer = ''; $buffer = '';
for($x = 0; $x < mb_strlen($str); $x ++) { $len = mb_strlen($str);
for($x = 0; $x < $len; $x ++) {
$char = $str[$x]; $char = $str[$x];
switch( $char ) { switch( $char ) {