Firefox PHP

MySQL database layer is unable to determine PHP MySQL extension to use

Posted by summiner 
MySQL database layer is unable to determine PHP MySQL extension to use
September 18, 2020 10:46PM
The past few days I have been moving my forum website from xenforo to phorum (xenforo costs $160 USD/year) and can't get past connecting phorum to the mysql database. I am using php 7.3.19, apache2, and mysql 8.0.21 Community

php error:

[Sat Sep 19 02:31:13.436257 2020] [php7:error] [pid 13014] [client 38.133.243.8:33066] PHP Fatal error: The Phorum MySQL database layer is unable to determine the PHP MySQL extension to use. This might indicate that there is no extension loaded from the php.ini. in /var/www/html/phorum/include/db/mysql.php on line 7774

mysql error:

None (oddly)

thanks for the help <3 - summiner
Re: MySQL database layer is unable to determine PHP MySQL extension to use
September 20, 2020 11:06PM
[www.php.net]
Quote

Depending on the version of PHP, there are either two or three PHP APIs for accessing the MySQL database. PHP 5 users can choose between the deprecated mysql extension, mysqli, or PDO_MySQL. PHP 7 removes the mysql extension, leaving only the latter two options.

Make sure your Phorum config is set to use "mysqli" an not "NULL" --- phorum/include/db/config.php
Somewhere about line 43 in config.php
    // Use which MySQL PHP extension? Either NULL, "mysql", "mysqli" or
    // "mysqli_replication" for master/slave setups.
    // If NULL, Phorum will autodetect the extension to use.
    // See the end of this file for a detailed description of this option.
    // 'mysql_php_extension' =>  NULL,
    'mysql_php_extension' =>  "mysqli" ,

Make sure the "mysqli" extension exists, and is loaded in the php.ini --- you might have your own if the Host allows it, or the Host may be totally in control.
Re: MySQL database layer is unable to determine PHP MySQL extension to use
September 24, 2020 07:28PM
Thanks for your reply, I have fixed my issue I was using a custom mysql user which had no permissions on accident. I feel like a total idiot honestly but thanks for your help <3

edit: and I also changed NULL to mysqli when I was trying to debug so it was a win-win at the time xD



Edited 1 time(s). Last edit at 09/24/2020 07:29PM by summiner.
Sorry, only registered users may post in this forum.

Click here to login