/** * Resets template, language and menu xml cache */ public function resetCache() { $aTemplates = $this->getModule()->getTemplates(); $oUtils = Registry::getUtils(); $oUtils->resetTemplateCache($aTemplates); $oUtils->resetLanguageCache(); $oUtils->resetMenuCache(); ModuleVariablesLocator::resetModuleVariables(); $this->_clearApcCache(); }
/** * error_404_handler handler for 404 (page not found) error * * @param string $sUrl url wich was given, can be not specified in some cases * * @return void */ function error_404_handler($sUrl = '') { Registry::getUtils()->handlePageNotFoundError($sUrl); }
/** * Returns alternative image url * * @param string $sFilePath path to file * @param string $sFile filename in pictures dir * @param bool $blSSL is ssl ? * * @return string */ public function getAltImageUrl($sFilePath, $sFile, $blSSL = null) { $oConfig = $this->getConfig(); $sAltUrl = $oConfig->getConfigParam('sAltImageUrl'); if (!$sAltUrl) { $sAltUrl = $oConfig->getConfigParam('sAltImageDir'); } if ($sAltUrl) { if (is_null($blSSL) && $oConfig->isSsl() || $blSSL) { $sSslAltUrl = $oConfig->getConfigParam('sSSLAltImageUrl'); if (!$sSslAltUrl) { $sSslAltUrl = $oConfig->getConfigParam('sSSLAltImageDir'); } if ($sSslAltUrl) { $sAltUrl = $sSslAltUrl; } } if (!is_null($sFile)) { $sAltUrl = Registry::getUtils()->checkUrlEndingSlash($sAltUrl) . $sFilePath . $sFile; } } return $sAltUrl; }
/** * Redirect to start page and display the error * * @param oxException $ex message to show on exit */ protected function _handleCookieException($ex) { $this->_processSeoCall(); //starting up the session $this->getSession()->start(); // redirect to start page and display the error Registry::get("oxUtilsView")->addErrorToDisplay($ex); Registry::getUtils()->redirect($this->getShopHomeUrl() . 'cl=start', true, 302); }
public function testGetLUtils() { $oSubj = Registry::getUtils(); $this->assertTrue($oSubj instanceof \OxidEsales\EshopCommunity\Core\Utils); }