Problems with your MySQL (mysqli) support
HI
Trying to install Zencart onto my domain and not getting past the following.
Any idea what to do?
ISP / Host says that my hosting platform does support musqli
System Inspection
TIP: For some errors and warnings below, more information may be available by clicking on the error/warning title.
Some problems that need fixing before we continue
Problems with your MySQL (mysqli) support
Re: Problems with your MySQL (mysqli) support
You might ask your current web-host why they've chosen not to support mysqli, given that the mysql support in PHP has been removed starting with PHP 7.0.
It they're not bendable on that, you'll need to find a new web-host for your later-than-v1.5.2 Zen Cart.
Re: Problems with your MySQL (mysqli) support
Perhaps you could generate the php settings to see what is currently seen by your ZC site area.
Create a file with a "random" name of your choosing with the extension .php and store it at a location accessible by your store's url (ie. In the root of your store) with the following contents:
Code:
<?php echo phpinfo(); ?>
Then point your browser to that file, copy and paste the result then remove the file.
Re: Problems with your MySQL (mysqli) support
I have asked them and they said it is supported. Will confirm again, and that in fact my domain has feature.
as per myphp
Web server
cpsrvd 11.54.0.21
Database client version: libmysql - 5.1.73
PHP extension: mysqli Documentation
Re: Problems with your MySQL (mysqli) support
I am also getting this error when I try to create a new install at MYDOMAIN/1.5.8 I set that folder to use PHP version: 8.2.13 whereas the root folder (which is still running Zen Cart 1.5.4) still has PHP version: 5.6.40
in cPanel > Select PHP Version I see mysqli enabled. Running phpinfo(); in MYDOMAIN/1.5.8 throws hundreds of lines of content. The Configure Command section does have:
Code:
'./configure' '--prefix=/usr' ... '--without-mysqli'
I will keep exploring Stack Overflow and the PHP and MySQL documentation.
Re: Problems with your MySQL (mysqli) support
There was a time when you had to run the PHP Configuration tool in cPanel and check a box that you wanted mysqli. Perhaps your hoster has something similar.
Re: Problems with your MySQL (mysqli) support
Additionally, may want to consider setting up this additional store using a sub domain. The sub domain could still be in this sub directory off your main site, but the alternate php configuration may play better.
Re: Problems with your MySQL (mysqli) support
cPanel shows mysqli as enabled with the default PHP version. The host is tweaking some things and they may have a recommended fix.
Zen Cart seems to expect that a few files like favicon.io are in specific places relative to the root.
Creating a site in a subdomain like store.DOMAINNAME.TLD is kind of trendy.
Re: Problems with your MySQL (mysqli) support
The host seems to have set it up so that nd_mysqli overrides mysqli. "nd_pdo_mysql appears to be a custom plugable extension provided by the cPanel hosting platform in order to opt-in the MySQL Native Driver in run-time. " (Stack Overflow) Nobody on the ZC support forum seems to have had trouble with a host using nd_mysqli instead of the basic mysqli extension until now so I am talking to the host.
The Zen Cart 1.5.4 install seems to still work with PHP 7.4 but we have not tried moving all the way to 8.2 since the language changed so much.
Re: Problems with your MySQL (mysqli) support
When we remove the .htaccess rule trying to enable a different PHP version than the server default, the errors about missing PHP extensions go away, and there is just a warning "For maximum security and compatibility you should be using PHP 8.0 or newer. " (Currently the default is PHP 7.4 so that the ZC 1.5.4 install continues to work).
Re: Problems with your MySQL (mysqli) support
Some of the latest cPanel updates are not providing "mysqli" as an extension. (Those same cPanel updates are also progressively pushing forward with things that will eventually make your old ZC 1.5.4 unable to run without upgrading.)
In the meantime, you can bypass zc_install's check for "mysqli" by editing one of the zc_install files:
/zc_install/includes/systemChecks.yml (around line 70 depending on the ZC version):
Code:
mysqlExt:
runLevel: always
errorLevel: FAIL
criticalError: true
Make 2 changes to that "mysqlExt:" section: change that FAIL to WARN, and remove the criticalError: true line.
Re: Problems with your MySQL (mysqli) support
Not sure if this is the right place for this, but here goes...
Recently I (finally) upgraded to 1.5.7 from 1.5.6 (and yes I am currently working on 1.5.8).
I've been live with 1.5.7 since feb 5th and it's been running fine, except I was looking at the logs the other day and on the 13th I had several instances of this -
PHP Warning: mysqli_connect(): (HY000/1040): Too many connections in /home/funkybal/public_html/zencart/includes/classes/db/mysql/query_factory.php on line 63.
I've never come across this before and it hasn't occurred since.
Is this possibly a one off where too many people were trying to access my zencart or could something else be an issue?
For the record I make use of multisite, my zencart has 12 faces which are geographic representations of my store. One theory is being the 13th I might have had a spike in activity across all sites for people desperate to order for valentines day?
Re: Problems with your MySQL (mysqli) support