w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Database connection error when I am trying to connect mysql database in my YII application

replace this

'connectionString' => 'mysqli:host=localhost;dbname=yii_amar'

with this

'connectionString' => 'mysql:host=localhost;dbname=yii_amar'

dsn should start with mysql.

"could not find driver" comes from PDO. Check if pdo_mysql extension installed via phpinfo.

© Copyright 2018 w3hello.com Publishing Limited. All rights reserved.