Call to undefined function mysql_connect()

If you are runnig Joomla 3.x and Virtuemart 3.x please post to this forum your questions or support tickets about One Page Checkout

Call to undefined function mysql_connect()

Postby tomrinkes » Tue May 09, 2017 3:13 pm

Hello,


I have installed 2.0.338.260417 and when I switch from PHP 5.6 to PHP 7.0 I get this problem
Call to undefined function mysql_connect()

It happens when the order is complet and the custumer goes to the paymentprovider.
What can I do?

J3.6.5
VM3

Greetings

Tom Rinkes
Attachments
fail.jpg
fail.jpg (134.78 KiB) Viewed 15930 times
fail.jpg
fail.jpg (134.78 KiB) Viewed 15930 times
tomrinkes
 
Posts: 5
Joined: Tue May 09, 2017 2:58 pm

Re: Call to undefined function mysql_connect()

Postby admin » Tue May 09, 2017 6:04 pm

hello, mysql_* functions are deprecated in php7.

please change your database type either in joomla global config to "mysqli" or modify your configuration.php to

Code: Select all
public $dbtype = 'mysqli';


if any of your 3rd party extension uses the mysql_* functions it will cause this error.

you can use OPC utils to find the extension by search all your server's files. search for "mysql_" in all *.php files.

OR

you can use OPC's fatal catcher plugin to indentify which extension causes this.

best regards, stan
admin
Site Admin
 
Posts: 2708
Joined: Wed Jan 06, 2010 11:43 pm

Re: Call to undefined function mysql_connect()

Postby tomrinkes » Wed May 10, 2017 10:10 am

Hello Stan,

the database is mysql already, the problem only accurs what OPC is turn on.
OPC's fatal catcher plugin is turn on but I do not recieve any emails.

Thank you for you help

Greetings,

Tom
tomrinkes
 
Posts: 5
Joined: Tue May 09, 2017 2:58 pm

Re: Call to undefined function mysql_connect()

Postby tomrinkes » Wed May 10, 2017 10:31 am

What I mean is that the error only accurs when OPC and PHP 7 are on. When OPC is off and PHP 7 is on their is no problem.
OPC works well when I turn on PHP 5.6
tomrinkes
 
Posts: 5
Joined: Tue May 09, 2017 2:58 pm

Re: Call to undefined function mysql_connect()

Postby admin » Wed May 10, 2017 2:39 pm

hello OPC loads your payment + calculation + coupon + shipment + custom field + shopper field plugins and if this function is used by any of them, it will cause an error.

first of all, please identify the file which causes the problem with our fatal catcher. (click install at the OPC Extensions tab + enable in joomla plugins)

generally it's recomended to:
- disable all unused payment + shipping plugins within the joomla plugin manager so they don't get loaded when they are not used (otherwise they do get loaded by joomla plugin system and may cause various problems... )

i did a check in OPC code and the only part using the obsolete function is our "centitrade payment plugin" after the checkout. if you are using this plugin, we are going to release an update.

best regards, stan
admin
Site Admin
 
Posts: 2708
Joined: Wed Jan 06, 2010 11:43 pm

Re: Call to undefined function mysql_connect()

Postby admin » Wed May 10, 2017 2:43 pm

ok, if the fatal catcher is not capable of sending the emails:
- your site's email may not work at all - pls see if you can send emails from Joomla generally
- update the fatal catcher from the OPC318 as we did a few updates for php7.1

if none of this helps, pls review your "php error log" for this fatal error AND/OR check "fatal catcher error log" if written in /logs directory AND/OR enable Developer error reporting in your Joomla global config to see the error on the screen AND/OR ask your hosting to locate the file which causes the problem via the php error logs.

if none of this helps, you can use OPC utils to full-text-search all your php files for "mysql_" keyword to see which part of the system uses it.

best regards, stan
admin
Site Admin
 
Posts: 2708
Joined: Wed Jan 06, 2010 11:43 pm

Re: Call to undefined function mysql_connect()

Postby tomrinkes » Thu May 11, 2017 12:37 pm

I have the fatal catcher working.

is this the problem?
Error message data:
8 Undefined index: email in file: /domains/twr-trading.nl/public_html/components/com_onepage/controllers/opc.php line: 5109
tomrinkes
 
Posts: 5
Joined: Tue May 09, 2017 2:58 pm

Re: Call to undefined function mysql_connect()

Postby admin » Thu May 11, 2017 2:17 pm

hello, no - you probably enabled to send notices as well - please disable them as you can receive a few thousands emails in a few minutes and thus your email servers will be blocked within an hour.

if you'd like i can check your site online via FTP and backend, please contact us via email or live chat.

best regards, stan
admin
Site Admin
 
Posts: 2708
Joined: Wed Jan 06, 2010 11:43 pm

Re: Call to undefined function mysql_connect()

Postby tomrinkes » Fri May 12, 2017 10:56 am

Hello Stan,

I think I found the problem, it is not with OPC but with the paymentprovider called Ideaal-checkout.
Thank for you help.

Greetings,

Tom
tomrinkes
 
Posts: 5
Joined: Tue May 09, 2017 2:58 pm

Re: Call to undefined function mysql_connect()

Postby admin » Mon May 15, 2017 7:59 pm

hello, you are welcome, best regards, stan
admin
Site Admin
 
Posts: 2708
Joined: Wed Jan 06, 2010 11:43 pm


Return to One Page Checkout for Virtuemart 3 on Joomla 3.x