PHP notice

Undefined index: Yii_graduate

/home/u0138678/5.u0138678.z8.ru/docs/protected/controllers/PageController.php(122)

110         );
111     }
112 
113     /**
114      * Displays a particular model.
115      * @param integer $id the ID of the model to be displayed
116      */
117     public function actionView($id)
118     {
119     if(!Yii::app()->user->isGuest){
120         $user = User::model()->find('username=:username', array(':username'=>Yii::app()->user->name));
121     }else{
122         if( User::model()->find('username=:username', array(':username'=>$_COOKIE["Yii_graduate"]))!=NULL){
123             $users=new User;
124             $users->username=$_COOKIE['Yii_graduate'];
125             $users->save();
126         }
127     }    
128         $model=$this->loadModel($id);
129         $criteria=new CDbCriteria();
130         $criteria->condition='page_id=:id';
131         $criteria->params=array(':id'=>$model->id);
132         $criteria->order=("t.id DESC");
133         //$criteria->order=("t.id ASC");
134         $count=Comment::model()->count($criteria);

Stack Trace

#14
+
 /home/u0138678/5.u0138678.z8.ru/docs/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-28 22:08:01 Apache/2.4.53 (Red Hat Enterprise Linux 8) PHP/5.3.29 Yii Framework/1.1.14