$v) { if(is_array($v)) stripslashes_recursively($array[$k]); else $array[$k] = stripslashes($v); } } /** * This is the main translator function. Returns the string defined by $class and $entity according to the currently set locale */ function _($class, $entity, $string="", $priority=100, $context="") { global $lang; $locale = i18n::getLocale(); $class = ereg_replace('.*([/\\]+)',"",$class); if (substr($class,-4) == '.php') $class = substr($class,0,-4); if (!$lang[$locale][$class]) i18n::includeByClass($class); $transEntity = $lang[i18n::getLocale()][$class][$entity]; return (is_array($transEntity) ? $transEntity[0] : $transEntity); } ?>