예제 #1
0
 /**
  * Resets Zend Opcache cache if installed and enabled.
  * 
  * @param	string		$script
  */
 public static function resetZendOpcache($script = '')
 {
     if (self::$zendOpcacheEnabled === null) {
         self::$zendOpcacheEnabled = false;
         if (extension_loaded('Zend Opcache') && @ini_get('opcache.enable')) {
             self::$zendOpcacheEnabled = true;
         }
     }
     if (self::$zendOpcacheEnabled) {
         if (empty($script)) {
             opcache_reset();
         } else {
             opcache_invalidate($script, true);
         }
     }
 }
예제 #2
0
 /**
  * Changes the active language.
  *
  * @param	integer		$languageID
  */
 public static final function setLanguage($languageID)
 {
     self::$languageObj = LanguageFactory::getInstance()->getLanguage($languageID);
     self::getTPL()->setLanguageID(self::getLanguage()->languageID);
 }