PHP notice

Trying to get property of non-object

/home/u154840089/domains/abih-pb.com.br/public_html/2017/protected/controllers/SiteController.php(369)

357                 'pageSize' => 50000),
358         ));
359 
360 
361         $this->render('associados', array(
362             'dataProviderAssociados' => $dataProviderAssociados,
363         ));
364     }
365 
366     public function actionAssociado($id) {
367 
368         $associado = Hotel::model()->findByPk($id);
369         if ($associado->galeria_nome_) {
370             $condition = 'galeria_nome_=' . $associado->galeria_nome_;
371         } else {
372             $condition = 'id < 0';
373         }
374 
375         $dataProviderFotos = new CActiveDataProvider('Foto', array(
376             'criteria' => array(
377                 'select' => '*',
378                 'condition' => $condition,
379                 'order' => ' id DESC',
380                 'limit' => 50000
381             ),

Stack Trace

#9
+
 /home/u154840089/domains/abih-pb.com.br/public_html/2017/index.php(17): CApplication->run()
12 defined('YII_DEBUG') or define('YII_DEBUG',true);
13 // specify how many levels of call stack should be shown in each log message
14 defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3);
15 
16 require_once($yii);
17 Yii::createWebApplication($config)->run();
2024-03-28 13:46:24 LiteSpeed Yii Framework/1.1.13