PHP Problem (mysqli)?

black

New member
I'm having a small problem with some php code. I always get this error: Fatal error: Cannot instantiate non-existent class: mysqli in ../comment/getItemsFromDatabase.php on line 5

Code: $mysqli = new mysqli($server, $username, $password, $db) or die('There was a problem connecting');

If you wan't all the code download it here: http://nettuts.s3.amazonaws.com/486_ajaxComments/ajaxComment.zip

SOMEONE PLEASE HELP

Black
 
Your server probably doesn't have mysqli enabed.

You can go
<?php
phpinfo();
?>

There will be a mysqli section if its enabled.

If its not there, you can use mysql_connect();
Go here for more information on it
http://us2.php.net/manual/en/function.mysql-connect.php
 
Back
Top