CDbException

CDbConnection failed to open the DB connection: SQLSTATE[HY000] [1044] Access denied for user 'brdepylaction_yii'@'localhost' to database 'brdepyla_blog'

/home/brdepylaction/yii-1.1.13.e9e4a0/framework/db/CDbConnection.php(381)

369                 throw new CDbException('CDbConnection.connectionString cannot be empty.');
370             try
371             {
372                 Yii::trace('Opening DB connection','system.db.CDbConnection');
373                 $this->_pdo=$this->createPdoInstance();
374                 $this->initConnection($this->_pdo);
375                 $this->_active=true;
376             }
377             catch(PDOException $e)
378             {
379                 if(YII_DEBUG)
380                 {
381                     throw new CDbException('CDbConnection failed to open the DB connection: '.
382                         $e->getMessage(),(int)$e->getCode(),$e->errorInfo);
383                 }
384                 else
385                 {
386                     Yii::log($e->getMessage(),CLogger::LEVEL_ERROR,'exception.CDbException');
387                     throw new CDbException('CDbConnection failed to open the DB connection.',(int)$e->getCode(),$e->errorInfo);
388                 }
389             }
390         }
391     }
392 
393     /**

Stack Trace

#7
+
 /home/brdepylaction/public_html/site/protected/models/Imprensa.php(32): CActiveRecord::model("Imprensa")
27      * @param string $className active record class name.
28      * @return Outdoor the static model class
29      */
30     public static function model($className=__CLASS__)
31     {
32         return parent::model($className);
33     }
34 
35     /**
36      * @return string the associated database table name
37      */
#8
+
 /home/brdepylaction/public_html/site/protected/controllers/ImprensaController.php(16): Imprensa::model()
11     /**
12      * Acao principal
13      */
14 
15     public function actionIndex(){
16         $imprensaItens = Imprensa::model()->findAllByAttributes(array('ativo'=>1));
17         $this->render('index',array('imprensaItens'=>$imprensaItens));
18     }
19 
20     public function actionCreateZip($arquivo){
21         $path = YiiBase::getPathOfAlias("webroot")."/upload/imprensa/";
#16
+
 /home/brdepylaction/public_html/site/index.php(37): CApplication->run()
32 
33 require_once($yii);
34 
35 $config=dirname(__FILE__).'/protected/config/' . SERVER_ENV . '.php';
36 
37 Yii::createWebApplication($config)->run();
38 
39 ?>
2018-10-15 12:38:46 Apache Yii Framework/1.1.13