public function actionPageByUrl($url) { $page = Page::findByUrl($url); if (empty($page)) { throw new E404Exception(); } $this->data->page = $page; }