/** * Controller predispatch method * * Called before action method */ public function preDispatch() { parent::preDispatch(); if (!('installer' == strtolower($this->getRequest()->getModuleName()) && 'wizard' == strtolower($this->getRequest()->getControllerName()) && 'finish' == strtolower($this->getRequest()->getActionName())) && Uni_Core_Installer::isInstalled()) { $this->sendRedirect(''); } }
/** * Controller predispatch method * * Called before action method */ function preDispatch() { parent::preDispatch(); if (!Fox::getModel('member/session')->getLoginData()) { if (!('member' === strtolower($this->getRequest()->getModuleName()) && 'account' === strtolower($this->getRequest()->getControllerName()) && 'login' === strtolower($this->getRequest()->getActionName())) && !('member' === strtolower($this->getRequest()->getModuleName()) && 'account' === strtolower($this->getRequest()->getControllerName()) && 'create' === strtolower($this->getRequest()->getActionName())) && !('member' === strtolower($this->getRequest()->getModuleName()) && 'account' === strtolower($this->getRequest()->getControllerName()) && 'forgot-password' === strtolower($this->getRequest()->getActionName())) && !('member' === strtolower($this->getRequest()->getModuleName()) && 'account' === strtolower($this->getRequest()->getControllerName()) && 'verification' === strtolower($this->getRequest()->getActionName())) && !('member' === strtolower($this->getRequest()->getModuleName()) && 'account' === strtolower($this->getRequest()->getControllerName()) && 'change-forget-password' === strtolower($this->getRequest()->getActionName()))) { $this->sendRedirect('member/account/login'); } } else { Fox::getModel('member/session')->setSessionTimeout(Fox::getMemberSessionInterval()); } }