2.0.19 problem - Fatal/Uncaught Error

Started by gloudiesaurus, September 09, 2022, 09:39:58 AM

Previous topic - Next topic

gloudiesaurus

My forum (gppits.net/forum) stopped working, I got the following errors:

QuoteFatal error: Uncaught Error: Call to undefined function mysql_query() in /home/gppitsnet/domains/gppits.net/public_html/forum/Sources/Load.php(2272) : eval()'d code:296 Stack trace: #0 /home/gppitsnet/domains/gppits.net/public_html/forum/Sources/Load.php(1984): template_body_above() #1 /home/gppitsnet/domains/gppits.net/public_html/forum/Sources/Subs.php(3455): loadSubTemplate('body_above', true) #2 /home/gppitsnet/domains/gppits.net/public_html/forum/Sources/Subs.php(2900): template_header() #3 /home/gppitsnet/domains/gppits.net/public_html/forum/Sources/Errors.php(337): obExit(NULL, true, false, true) #4 /home/gppitsnet/domains/gppits.net/public_html/forum/Sources/Errors.php(161): setup_fatal_error_context('Call to undefin...') #5 /home/gppitsnet/domains/gppits.net/public_html/forum/index.php(132): fatal_error('Call to undefin...', 'critical') #6 [internal function]: {closure}(Object(Error)) #7 {main} thrown in /home/gppitsnet/domains/gppits.net/public_html/forum/Sources/Load.php(2272) : eval()'d code on line 296

How can I fix this?

gloudiesaurus


Kindred

#2
What version of smf?

Edit-  DOH! Just realized the op included the version in the title
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Doug Heffernan

Quote from: gloudiesaurus on September 09, 2022, 09:39:58 AMMy forum (gppits.net/forum) stopped working, I got the following errors:

What was the latest change/modification that was done to the forum prior to this happening?

If you are not already using smf 2.0.19, upgrade to it and see if that would help.

shawnb61

That looks like a mysql support issue.  Note it's mysql_query, not mysqli_query. 

I would have the host confirm mysqli is enabled.  Support for mysql (no i) ended in ~php7.

Running phpinfo should tell you if mysqli is enabled also.
Address the process rather than the outcome.  Then, the outcome becomes more likely.   - Fripp

gloudiesaurus

Quote from: shawnb61 on September 09, 2022, 11:31:58 AMThat looks like a mysql support issue.  Note it's mysql_query, not mysqli_query. 

I would have the host confirm mysqli is enabled.  Support for mysql (no i) ended in ~php7.

Running phpinfo should tell you if mysqli is enabled also.

Info from phpinfo:
Configure Command   './configure' '--enable-embed' '--prefix=/usr/local/php74' '--program-suffix=74' '--enable-fpm' '--with-fpm-systemd' '--enable-litespeed' '--with-config-file-scan-dir=/usr/local/php74/lib/php.conf.d' '--with-curl' '--enable-gd' '--with-gettext' '--with-jpeg' '--with-freetype' '--with-kerberos' '--with-openssl' '--with-mhash' '--with-mysql-sock=/var/lib/mysql/mysql.sock' '--with-mysqli=mysqlnd' '--with-pdo-mysql=mysqlnd' '--with-pear' '--with-sodium=/usr/local' '--with-webp' '--with-xsl' '--with-zlib' '--with-zip' '--with-iconv=/usr/local' '--enable-bcmath' '--enable-calendar' '--enable-exif' '--enable-ftp' '--enable-sockets' '--enable-soap' '--enable-mbstring' '--enable-intl' 'PKG_CONFIG_PATH=/usr/local/icu/lib/pkgconfig:/usr/local/lib64/pkgconfig:/usr/local/lib/pkgconfig:/usr/lib/x86_64-linux-gnu/pkgconfig'
Server API   FPM/FastCGI
Virtual Directory Support   disabled
Configuration File (php.ini) Path   /usr/local/php74/lib
Loaded Configuration File   /usr/local/php74/lib/php.ini
Scan this dir for additional .ini files   /usr/local/php74/lib/php.conf.d
Additional .ini files parsed   /usr/local/php74/lib/php.conf.d/10-directadmin.ini, /usr/local/php74/lib/php.conf.d/50-webapps.ini
PHP API   20190902
PHP Extension   20190902
Zend Extension   320190902
Zend Extension Build   API320190902,NTS
PHP Extension Build   API20190902,NTS
Debug Build   no
Thread Safety   disabled
Zend Signal Handling   enabled
Zend Memory Manager   enabled
Zend Multibyte Support   provided by mbstring
IPv6 Support   enabled
DTrace Support   disabled
Registered PHP Streams   https, ftps, compress.zlib, php, file, glob, data, http, ftp, phar, zip
Registered Stream Socket Transports   tcp, udp, unix, udg, ssl, sslv3, tls, tlsv1.0, tlsv1.1, tlsv1.2
Registered Stream Filters   zlib.*, convert.iconv.*, string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, dechunk

gloudiesaurus

Maybe upgrading to version 2.1.2 will help?

I'm running 2.0.19 now.

GL700Wing

Quote from: gloudiesaurus on September 12, 2022, 06:51:05 AMMaybe upgrading to version 2.1.2 will help?

I'm running 2.0.19 now.
I'd recommend that you get SMF 2.0.19 working properly and reliably before you attempt any upgrade ...
Life doesn't have to be perfect to be wonderful ...

Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

gloudiesaurus

Quote from: GL700Wing on September 12, 2022, 07:11:16 AM
Quote from: gloudiesaurus on September 12, 2022, 06:51:05 AMMaybe upgrading to version 2.1.2 will help?

I'm running 2.0.19 now.
I'd recommend that you get SMF 2.0.19 working properly and reliably before you attempt any upgrade ...

But the reason that it won't work is maybe because my hosting runs PHP 7.4 now?

Doug Heffernan

Quote from: gloudiesaurus on September 12, 2022, 07:22:02 AMBut the reason that it won't work is maybe because my hosting runs PHP 7.4 now?

Smf 2.0.19 works fine with php 7.4.

GL700Wing

Quote from: gloudiesaurus on September 12, 2022, 07:22:02 AMBut the reason that it won't work is maybe because my hosting runs PHP 7.4 now?
All my SMF 2.0.19 forums are working perfectly with PHP 7.4 - you have some other issue.
Life doesn't have to be perfect to be wonderful ...

Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Doug Heffernan

Quote from: gloudiesaurus on September 09, 2022, 09:39:58 AMMy forum (gppits.net/forum) stopped working....

Quote from: Doug Heffernan on September 09, 2022, 10:50:10 AMWhat was the latest change/modification that was done to the forum prior to this happening?

Additionally, can you refresh all your forum files with those from the large 2.0.19 upgrade package, without the upgrade files? Note that doing so it will uninstall all the mods that you have, and undo any manual changes to the files. If you have edited files manually, back them up first.

Then see if the error will go away. This is to see if a third party mod is causing this.

Steve

As the OP was here 3 days after Doug's post and didn't respond, I'm assuming this is no longer an issue and marking it solved.

And @gloudiesaurus - in future, please make your topic titles indicate the nature of your problem.
DO NOT pm me for support!

Advertisement: