Example #1
0
 /**
  *初始化语言包
  */
 public static function initLang()
 {
     $langFilePath = LANG_PATH . Request::getAcceptLang() . '.php';
     if (file_exists($langFilePath)) {
         self::$APPLang = (include $langFilePath);
     } elseif (file_exists(LANG_PATH . DEFAULT_LANG . '.php')) {
         self::$APPLang = (include LANG_PATH . DEFAULT_LANG . '.php');
     } else {
         self::$APPLang = array();
     }
 }