PHP notice

Trying to get property of non-object

/var/www/www.biologi.ipb.ac.id/protected/modules/web/controllers/AlumniController.php(44)

32                 $this->pageTitle = "Alumni";
33                 $this->layout='/layouts/onecolumn';
34                 $this->render('index', $viewData);
35 
36         }
37 
38         public function actionProgram($slug, $deg)
39         {
40                 if(!Yii::app()->request->isAjaxRequest)
41                 {
42                     $prog = DegreeProgram::model()->getBySlug($slug);
43                     $allPrograms = DegreeProgram::model()->getAll();
44                     $classYears = Alumni::model()->getClassYear($prog->id, $deg);
45 
46                     $viewData['allPrograms'] = $allPrograms;
47                     $viewData['program'] = $prog;
48                     $viewData['degree'] = $deg;
49                     $viewData['classYears'] = $classYears;
50 
51                     $this->pageTitle = Lang::t("Alumni " . $prog->name . " (" . $deg . ")" ,
52                                                "Alumni of " . $prog->name_en . " (" . $deg . ")" );
53                     $this->layout='/layouts/onecolumn';
54                     $this->render('list', $viewData);
55                 }
56                 else

Stack Trace

#9
+
 /var/www/www.biologi.ipb.ac.id/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 12:01:43 Apache Yii Framework/1.1.14