/** * Load the data */ protected function loadData() { //--Check the params if ($this->URL->getParameter(1) === null) { $this->redirect(FrontendNavigation::getURL(404)); } //--Get record $this->record = FrontendGalleriaModel::getAlbum($this->URL->getParameter(1)); //--Redirect if empty if (empty($this->record)) { $this->redirect(FrontendNavigation::getURL(404)); } }