Could not find driver MySQL with hhvm

I am using Laravel with HHVM.

MySQL is working in normal controller functions.

But whenever from Commands (artisan), DB connection of MySQL (PDO) is initialised, then error comes of "could not find driver".

Also I have tried writing connection initialisation from Controller function and calling it from Command still same error comes.

$conn = new \PDO("mysql:host=$servername;dbname=$db_name", $username, $password);


I think you have not installed php-mysql driver

Try installing by using following command

sudo apt-get install php5 php5-mysql

Make sure the PDO mysql driver is enabled.

If you're running debian/ubuntu, you can check like this

$ php -i | grep pdo
/etc/php5/cli/conf.d/20-pdo_mysql.ini, # <-- This line
pdo_mysql.default_socket => /var/run/mysqld/mysqld.sock => /var/run/mysqld/mysqld.sock

And if it's not enabled, you can enable it with:

$ php5enmod pdo_mysql

For other operating systems, you'll have to check the documentation.

Don't forget to restart your web server (Apache, or other).

Need Your Help

HTML5 game objects and sharing methods

javascript object html5-canvas

I'm having some issues understanding the code below for HTML5 game. This what i think is happening and was wondering if my understanding is correct?

Make radio buttons "checkable": HTML

html radio-button

How do I make radio buttons operate more like a check box? I need the function of a radio button, but it needs to be able to be de-selected.