Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: Milko on July 09, 2017, 02:33:59 PM

Title: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: Milko on July 09, 2017, 02:33:59 PM
I just ran the update from SMF 2.0.13 to 2.0.14, which rendered my forum inaccessible. I got this error message:

Fatal error: Function name must be a string in .../forum/Sources/Load.php on line 142

Can anyone help with this please?

Thanks!
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: Shambles on July 09, 2017, 02:49:24 PM
Reported many many times.

https://www.simplemachines.org/community/index.php?topic=554067
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: Milko on July 09, 2017, 03:04:09 PM
Many thanks for your prompt reply. I restored the Sources files to the ones before the update so my forum is now online running SMF 2.0.13. What I find weird is that there was a note relating to this update, saying that my PHP version must be 5.3 or higher. Mine is 5.3.29, so I thought - great, I'll do it. Now I see PHP must actually be 5.4.. And even then errors occur.. So, now I wonder if I should install this update at all..
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: Illori on July 09, 2017, 04:13:47 PM
you need to install the update so that you can install future updates as they become available.
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: Milko on July 10, 2017, 12:12:13 AM
My forum shows it's running SMF 2.0.14 now (SMF package 2.0.14) and only the Source files are SMF 2.0.13. I guess, it's because I restored only the Sources files and the PHP version is still 5.3. The forum is working fine, so far no bugs detected.

My question is, should I reinstall SMF 2.0.14 now? I have the choice to install any PHP version up to version 7.1. Is PHP 5.4 the most appropriate for SMF 2.0.14?
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: Kindred on July 10, 2017, 12:42:06 AM
7.x or 5.6 is better

however, if part of your forum is at 2.0.14 and part is at 2.0.13, you are going to have some major issues

and no... reinstalling the 2.0.14 patch will just cause more issues.... you are going to have to do a full update (replace the files with clean forum files and then reinstall mods)
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: BuxarNET on September 15, 2017, 05:48:23 PM
I also had the same problem.
before installing the forum, I pre-made a copy of all the files.
I had to return everything back, and the version returned to 2.1.13.
For the database, I did not return. Necessary?
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: =aXe= on October 20, 2017, 01:49:14 PM
I have the same fatal error on line 142 atm and dead forum. The problem is that due to need of using php 5.3 I cannot upgrade to later version of it. I can return the forum to 2.0.12, being the last update I was having an hour ago, but can I still update to 2.0.13 and continue to use this version in future while having php5.3?

Edit: Its essential for me to be on php5.3, because of my website system not being able to run on newer php version. Also I encounter the problem with reCAPTCHA v1, which soon is going to be dropped from Google. Still can't find mod to make the forum use the new reCaptcha v2 supported by Google. The old one v1, I followed the guide here to make it work, but with the new one I don't know how to integrate it!
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: shawnb61 on October 20, 2017, 02:07:34 PM
php 5.4 is required on 2.0.14 & newer. 

Sooner or later, you must grapple with a php upgrade. 

Hope this helps,
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: =aXe= on October 20, 2017, 03:43:54 PM
I restore it to 2.0.12 and its working again. I will see what will do in future with php5.4 being needed. Still does anyone know how to implement v2 reCaptcha? Is there any topic or some guide/mod for Google's v2?
Thanks in advance!
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: Sir Osis of Liver on October 20, 2017, 11:05:49 PM
You should upgrade to 2.0.13, it will work in php 5.3.  IIRC, 2.0.12 had some bugs.

Re: reCaptch - https://www.simplemachines.org/community/index.php?topic=213535.msg3945459#msg3945459
Title: Re: Fatal error: Function name must be a string in ../forum/Sources/Load.php
Post by: ladyweb on October 22, 2017, 08:38:56 AM
Quote from: Milko on July 10, 2017, 12:12:13 AM
My forum shows it's running SMF 2.0.14 now (SMF package 2.0.14) and only the Source files are SMF 2.0.13. I guess, it's because I restored only the Sources files and the PHP version is still 5.3. The forum is working fine, so far no bugs detected.

My question is, should I reinstall SMF 2.0.14 now? I have the choice to install any PHP version up to version 7.1. Is PHP 5.4 the most appropriate for SMF 2.0.14?

I had problems with missing deb packages for dependencies for php7.1 so I suggest not going any higher than php7.0 for now.