function pageEntry($inPath) { SLanguage::setLanguageDir(SlightPHP::$appDir . "/../locale"); SLanguage::setLocale("en"); echo SLanguage::tr("name", "main"); SLanguage::setLocale("zh-cn"); echo SLanguage::tr("name", "main"); }
public static function setLocale($locale) { self::$locale = $locale; }
function tpl_modifier_tr($string, $zone = "main") { return SLanguage::tr($string, $zone); }