Upgrading Frontaccounting and php72 to php74

I ran into trouble while pkg upgrading frontaccounting to the latest version and shifting to php74. I had previously used php72 and php72-mysqli extension with no problem in frontaccounting. but the setup wizard refuses to acknowledge php74 has Mysql extension enabled.
 
That's not much info to go on.

Did you see any errors during updating?

Have you tried php -m to see if the module is listed?

Is frontaccouting web-based? Do you need to restart apache if you are using mod_php?

If you make a simple web page with just <?php phpinfo(); ?> does it show the MySQL extension?
 
I ran into trouble while pkg upgrading frontaccounting to the latest version and shifting to php74.
Often made mistake, you still have www/mod_php72 installed, you need to install www/mod_php74. The upgrade doesn't do this for you. So you end up with various PHP 7.4 modules but mod_php72 is still active.
 
Unluckily that was not the case: checked it out, and mod_php74 is correctly installed :( (And mod_php72 uninstalled)
 
I tried reinstalling apache24, mod_php74. When I check with phpinfo it tells me everything's fine. Handler for mysql installed. But the frontaccounting wizard continues to complain about Your PHP has to have MySQL extension enabled.
 
Looking at the source this error seems to come up if it can't find the mysqli_connect function.
If you run the command below on the cli does it output a load of stuff or say the extension doesn't exist?

Code:
php --re mysqli
 
I just found out that in the "frontaccounting/includes/system_test.inc", file for checking the requisites before installation, a test is made on the presence of mysql_connect and not on the "modern" mysqli_connect. That should be changed. My php mysqli extension is working fine...
 
and... of course... I need to substitute *every* occurrence of mysql_ occurring in db maintenance files with mysqli_ . Then I'll see if it works...
 
out of curiosity mysql connector was dropped in php v7.0 so how is it possible previous version of frontaccounting was working with php 7.2 and updated version of frontaccounting tries to use mysql which is not available since php v7.0
 
Ok. I feel quite a troglodyte now, and will stop tampering with the thing. All function calls from mysqli need more parameters than their corrispective mysql ones. I'll go on another time.
 
Maybe I’m looking at the wrong project but on GitHub it has been loading the mysqli version of the db library includes/db/connect_db_mysqli.inc since 2014, but only if it can find the mysqli_connect function. If it can’t it falls back to the old mysql module, and will just give the above error if mysql_connect doesn’t work.

I haven’t bothered to download the source that ports is using, but if it’s the same software then I’d wager it’s still an issue with the web app seeing the mysqli driver. The port makefile lists mysqli as a requirement so the version the port is downloading clearly isn’t coded to require the old extension.
 
Back
Top