PHP notice

Trying to get property of non-object

/srv/http/btrworlds.com/htdocs/protected/modules/showroom/components/SController.php(644)

632             $ch = curl_init();
633             curl_setopt($ch, CURLOPT_URL, $dataUrl);
634             curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
635             $ua = isset($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_AGENT'] : 'curl/7.29.0';
636             curl_setopt($ch, CURLOPT_USERAGENT, $ua);
637             curl_setopt($ch, CURLOPT_TIMEOUT, 10);
638             $rData = curl_exec($ch);
639         } else {
640             $rData = file_get_contents($dataUrl);
641         }
642         if (!empty($rData)) {
643             $countryData = json_decode($rData);
644             if ($countryData->code == 0) {
645                 $countryCode = strtolower($countryData->data->country_id);
646             }
647         }
648         return $countryCode;
649     }
650     public  function getCompanyName(){
651 
652         $companyName=isset($this->company->companyname) ? $this->company->companyname :'';
653         return LibCommon::profilename($companyName);
654 
655     }
656 

Stack Trace

#0
+
 /srv/http/btrworlds.com/htdocs/protected/modules/showroom/components/SController.php(618): SController::remoteGetCountry("52.205.218.160")
613         if ($ip == '192.168.0.88')
614             return true;
615         if (function_exists('geoip_country_code_by_name')) {
616             $country = strtolower(geoip_country_code_by_name($ip));
617         } else {
618             $country = self::remoteGetCountry($ip);
619         }
620         return ($country == 'cn');
621     }
622 
623     /**
#1
+
 /srv/http/btrworlds.com/htdocs/protected/modules/showroom/controllers/DefaultController.php(14): SController->isFromCN()
09         if ($pageUrl == 'aboutus'){
10             $pageUrl = 'aboutus';
11             $memberInfo = $this->getMemberInfo();
12 
13             //video;为中国IP的youtube代码显示图,其它显示视频代码
14             if ($this->isFromCN() && strpos($this->company->flashvideo, '.youtube.')) {
15                 /* preg_match('/<.*?src=[\'|\"](.*?)[\'|\"].*?[\/]?>$/', $this->company->flashvideo, $videoUrl); */
16                 if (isset($this->company->rd) && !empty($this->company->rd))
17                     $this->company->flashvideo = (CHtml::link(CHtml::image(Yii::app()->baseUrl . Yii::app()->params['companydir'] . $this->company->adver_photo, '', array('max-height' => '600', 'max-weight' => '600')), $this->company->rd, array('target' => '_blank', 'rel' => 'nofollow')));
18             }
19         }
#11
+
 /srv/http/btrworlds.com/htdocs/index.php(17): CApplication->run()
12 // specify how many levels of call stack should be shown in each log message
13 defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL', 0); 
14 
15 require_once($yii);
16 
17 Yii::createWebApplication($config)->run();
2024-03-19 07:11:03 nginx/1.4.7 Yii Framework/1.1.12