Search code examples
mysqlcakephp

CakePHP 3 is NOT able to connect to the database due to a missing PHP extension


I am trying to install cakePHP 3.0.0 with WT-NMP, but i got this message:

CakePHP is NOT able to connect to the database.

Database driver Cake\Database\Driver\Mysql cannot be used due to a missing PHP extension or unmet dependency

my php.ini has this:

extension = php_bz2.dll
extension = php_curl.dll
extension = php_gd2.dll
extension = php_imap.dll
extension = php_mbstring.dll
extension = php_exif.dll
extension = php_mysql.dll
extension = php_mysqli.dll
extension = php_pdo_mysql.dll
extension = php_pdo.dll
extension = php_soap.dll
extension = php_sockets.dll
extension = php_sqlite3.dll
extension = php_openssl.dll
extension = php_fileinfo.dll
extension = php_intl.dll

the app.php has this

    'default' => [
        'className' => 'Cake\Database\Connection',
        'driver' => 'Cake\Database\Driver\Mysql',
        'persistent' => false,
        'host' => 'localhost',
        /**
         * CakePHP will use the default DB port based on the driver selected
         * MySQL on MAMP uses port 8889, MAMP users will want to uncomment
         * the following line and set the port accordingly
         */
        'port' => '3306',
        'username' => 'root',
        'password' => '',
        'database' => 'test',
        'encoding' => 'utf8',
        'timezone' => 'UTC',
        'cacheMetadata' => true,

What am I missing? or this is cakePHP 3.0 bug? OR anything to do with WT-NMP. I have been stuck for whole day.


Solution

  • Solved this by luck!:

    extension = php_intl.dll
    extension = php_pdo_mysql.dll
    intl.default_locale = en_utf8
    intl.error_level = E_WARNING