/** * Construct controller. */ public function before() { parent::before(); $this->auto_render = $this->_request_type === Controller::REQUEST_INITIAL; $this->history = $this->history && !$this->ajax; // Initialize Ads Ads::init(); // Load the template if ($this->auto_render === true) { $this->view = View_Page::factory(); } }