How to solve Fatal error: Class 'MySQLi' not found?
Sounds like you just need to install MySQLi.
If you think you've done that and still have a problem, please post your operating system and anything else that might help diagnose it further.
MySQLi not found error
I got the error corrected by enabling/editing the following config in php.ini
:
1st (uncomment and add config):
include_path = "C:\php\includes"
2nd (uncomment):
extension_dir = "ext"
3rd (uncomment and edit config):
extension=D:/PHP/ext/php_mysql.dll
extension=D:/PHP/ext/php_mysqli.dll
PHPUnit, Fatal error: Class 'mysqli' not found
I am not sure if you have configured your php.ini
file with the correct path, either DLL or shared object (.so) file. Try running, if you're using Unix/Linux, on your command line,
$> php -i | grep mysqli
and see if it says something being installed, or create a PHP script
<?php phpinfo(); ?>
Run that script and check if it's loaded correctly or not. If you are confident that it was really installed, try checking your php.ini file if it was loaded correctly by checking your "extension" section of php.ini.
Check also when running your PHPUnit, if it's in command line, because it might you have a different path for php.ini vs your php.ini when running in web mode.
Related Topics
PHPexcel Runs Out of 256, 512 and Also 1024Mb of Ram
Warning About '$Http_Raw_Post_Data' Being Deprecated
How to Automatically Start a Download in PHP
PHP: Regex to Ignore Escaped Quotes Within Quotes
Index.PHP Not Loading by Default
PHP Check If Date Between Two Dates
How to Filter a Two Dimensional Array by Value
PHPmailer: Smtp Error: Could Not Connect to Smtp Host
How to Call Shell Script from PHP That Requires Sudo
Error With PHP Mail(): Multiple or Malformed Newlines Found in Additional_Header
PHP Fatal Error: Cannot Redeclare Class
How to Write into a File in PHP
Detect Bad Json Data in PHP Json_Decode()
Capturing Text Between Square Brackets in PHP
Http Requests With File_Get_Contents, Getting the Response Code