MySQLi and PHP5


#1

Hi there,
I’ve recently joined Dreamhost and I’m in the process of porting my old content into a new PHP/MySQL schema and code base. On my local machine I’m using PHP5, Apache 2 and MySQL 5, but I’m having trouble with getting my scripts to work on the live server: PHP keeps spitting out the following message:

Fatal error: Cannot instantiate non-existent class: mysqli in /home/.genie/mattwilcox/matt-wilcox.net/index.php on line 24

Does Dreamhost’s PHP5 install not come pre-configured with the MySQLi module??? Or am I overlooking something fundamental?


#2

Don’t worry, I realised PHP4 is the default. I’ve enabled PHP5 and now it’s working. Sorry about that.


#3

You can check for the MySQLi module extension by calling the phpinfo() function. If it is installed, you will find it under #module_mysqli.


Simon Jessey
Keystone Websites | si-blog