Error

Non-static method Menu::getMenuByPath() cannot be called statically

/customers/a/d/7/psht-venlo.nl/httpd.www/protected/controllers/SiteController.php(71)

59         // using the default layout 'protected/views/layouts/main.php'
60         $this->render('article',array('article'=>$article));
61     }
62 
63     /**
64      * This is the default action that is invoked
65      * when a menu is aquired.
66      * @param type $menuPath
67      */
68     public function actionMenu($menuPath)
69     {
70         // retrieve the active menu object
71         $menu = Menu::getMenuByPath($menuPath);
72 
73         if($menu === null) {
74             throw new CHttpException(404, Yii::t('content', 'Oops, something goes wrong searching this page.'));
75         }
76 
77         // retrieve the article from the AR
78         $articles=Article::getArticlesByMenuId($menu->id);
79         $this->menuId = $menu->id;
80 
81 //        var_dump('<pre>', $articles); die('</pre>');
82 
83         // renders the view file 'protected/views/site/article.php'

Stack Trace

#9
+
 /customers/a/d/7/psht-venlo.nl/httpd.www/index.php(13): CApplication->run()
08 defined('YII_DEBUG') or define('YII_DEBUG',true);
09 // specify how many levels of call stack should be shown in each log message
10 defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3);
11 
12 require_once($yii);
13 Yii::createWebApplication($config)->run();
2024-03-19 09:58:17 Apache Yii Framework/1.1.14