Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- class ControllerCommonCheckLogin extends Controller {
- public function index() {
- // Require to be logged in
- if (!$this->customer->isLogged()) {
- $route = '';
- if (isset($this->request->get['route'])) {
- $part = explode('/', $this->request->get['route']);
- if (isset($part[0])) {
- $route .= $part[0];
- }
- }
- // Show site if logged in as admin
- $this->load->library('user');
- $this->user = new User($this->registry);
- if ((($route != 'payment') || ($route != 'account')) && !$this->user->isLogged()) {
- return $this->forward('common/maintenance/info');
- }
- }
- }
- }
- ?>
Add Comment
Please, Sign In to add comment