Database connection error after updating to PHP7
cPanelJacob announced (PHP7 support) PHP7 was available to install with easyapache 4.
I installed the base packages, enabled the option in the easyapache 4 provision profile and rebuit. Then in "MultiPHP Manager" select the domain to use PHP7.
The webpage gives this error when using PHP7:
"Database connection error (1): The MySQL adapter 'mysql' is not available.Database connection error (1): The MySQL adapter 'mysql' is not available."
The webpage works correctly in PHP 5.6.
I think I am missing some configuration setting in the PHP7 php.ini
-
Hi, Check out that blog post a little bit towards the bottom, specifically the deprecation section. PHP 7 no longer supports the MySQL extension, and by your error, your script will not work on PHP 7 because it's using a removed extension. You'll either need to upgrade your script, wait for the developers to support PHP 7, or this script might be stuck with using PHP 5. 0 -
Hi, Check out that blog post a little bit towards the bottom, specifically the deprecation section. PHP 7 no longer supports the MySQL extension, and by your error, your script will not work on PHP 7 because it's using a removed extension. You'll either need to upgrade your script, wait for the developers to support PHP 7, or this script might be stuck with using PHP 5.
yes, you should use "mysqli" instead of mysql0
Please sign in to leave a comment.
Comments
2 comments