CHttpException

/var/www/avtokolesnica/data/www/avtokolesnica.by/protected/controllers/frontend/NewsController.php(27)

15     public function actionList()
16     {
17         $news_tree = NewsTree::model()->active()->roots()->find('root = :root', array('root' => $this->root_id));
18         $news = News::model()->getProviderNews($this->getCurrentLanguage()->id, $news_tree->id);
19         $this->render('list', array('dataProvider'=>$news));
20     }
21 
22     public function actionItem($name)
23     {
24        $news=News::getNewsByName($name, $this->getCurrentLanguage()->id);
25        if (!$news)
26        {
27            throw new CHttpException(404);
28        }
29        $this->getPageModule('item');
30 
31        $this->setPageTitle($news->title);
32        $this->breadcrumbs[]=strip_tags($news->title);
33        $this->setSeoTags($news);
34        $this->setText($news);
35        $this->render('news',array('news'=>$news));
36     }
37 }

Stack Trace

#9
+
 /var/www/avtokolesnica/data/www/avtokolesnica.by/index.php(7): CApplication->run()
2 // include Yii bootstrap file
3 defined('YII_DEBUG') or define('YII_DEBUG',true);
4 require_once(dirname(__FILE__).'/../framework/yii.php');
5 $config=dirname(__FILE__).'/protected/config/frontend.php';
6 // create a Web application instance and run
7 Yii::createWebApplication($config)->run();
8 ?>
2024-03-28 11:47:31 Apache/2.4.6 (CentOS) mpm-itk/2.4.7-04 OpenSSL/1.0.2k-fips PHP/5.4.16 Yii Framework/1.1.17