CDbException

CDbConnection failed to open the DB connection: SQLSTATE[HY000] [2054] The server requested authentication method unknown to the client

/var/www/marketingkolding.dk/astro/protected/controllers/SiteController.php(169)

157     public $latest_users;
158     public $login_view='';
159     public function actionIndex(){ 
160     
161     
162     /*echo "hello".Yii::app()->errorHandler->error['code'];
163     echo Yii::app()->basePath;
164     print_r($_SESSION);
165     exit;*/
166         $this->layout="presentation";
167         $login_model=new LoginForm;
168         $register_model=new RegisterForm();
169         $this->latest_users = Yii::app()->db->createCommand('
170 SELECT u.id,u.firstname,u.lastname,u.username,i.file,FLOOR(DATEDIFF(CURRENT_DATE,up.birth_date)/365.25) AS age,ap.b_city,c.name as city_name,up.description
171 FROM tbl_user u
172 left join tbl_files i on u.id=i.ref_id and i.ref_type=1
173 left join tbl_user_profile_fields up on up.uid=u.id
174 left join tbl_user_astro_profile ap on ap.uid=u.id
175 left join cities c on c.ID = ap.b_city
176 where i.id is not null and u.id is not null and u.firstname is not null and u.lastname is not null and u.status="1"
177 order by u.id desc
178 limit 0,12
179         ')->queryAll();
180         $this->login_view = $this->renderPartial('login_partial',array(
181             'login_model'=>$login_model,

Stack Trace

#4
+
 /var/www/marketingkolding.dk/astro/protected/controllers/SiteController.php(169): CModule->__get("db")
164     print_r($_SESSION);
165     exit;*/
166         $this->layout="presentation";
167         $login_model=new LoginForm;
168         $register_model=new RegisterForm();
169         $this->latest_users = Yii::app()->db->createCommand('
170 SELECT u.id,u.firstname,u.lastname,u.username,i.file,FLOOR(DATEDIFF(CURRENT_DATE,up.birth_date)/365.25) AS age,ap.b_city,c.name as city_name,up.description
171 FROM tbl_user u
172 left join tbl_files i on u.id=i.ref_id and i.ref_type=1
173 left join tbl_user_profile_fields up on up.uid=u.id
174 left join tbl_user_astro_profile ap on ap.uid=u.id
#17
+
 /var/www/marketingkolding.dk/astro/index.php(41): CApplication->run()
36 //echo "<pre>";
37 //print_r($app);exit;
38 //1.1.15 version
39 //echo Yii::getVersion();exit;
40 //echo $app->user->identity;exit;
41 $app->run();
42 
2026-01-18 18:28:19 Apache Yii Framework/1.1.15