WebSite X5Help Center

 
Larry H.
Larry H.
User

Parse error: syntax error, unexpected T_FUNCTION  en

Автор: Larry H.
Просмотрено 1801, Подписчики 2, Размещенный 0  

I'm working on a website now in Website x5 and my form is not working: 

I get this error message when I test the form: Parse error: syntax error, unexpected T_FUNCTION in /home/landscap/public_html/res/x5engine.php on line 2019

frown

Larry

Размещено
7 Ответы - 2 Полезно
Paul M.
Paul M.
Moderator

Hello Larry,

In your own case I can safely say that particular error message is indicative of a PHP error.  You need to upgrade your version of PHP on the server to 5.6 or above.

Kind regards,

Paul

Search the WebSite X5 Help Center (multilingual)

Читать больше
Размещено От Paul M.
Aleksej H.
Aleksej H.
Moderator

Hello.Also try to reload the site to the hosting.Pre-delete from the hosting all the site files.

Читать больше
Размещено От Aleksej H.
Larry H.
Larry H.
User
Автор

Thanks for the help, I did upgrade the php with the cpanel and that didn't help. I will try to reload the site again and hopefully that will fix the issue. Thanks again. 

Читать больше
Размещено От Larry H.
Larry H.
Larry H.
User
Автор

I did upgrade the php with the cpanel to 7.0 and I did delete files for my hosting and reloaded the files, but I'm still getting this error when testing the form:

Parse error: syntax error, unexpected T_FUNCTION in /home/landscap/public_html/res/x5engine.php on line 2229

I'm also receiving this test failure when I'm loading the website files, see attached:

Here is the url: http://landscapedesigncharlottenc.com/

Thank you,

Larry

Читать больше
Размещено От Larry H.
Paul M.
Paul M.
Moderator

Hello again Larry,

I would advise you to have a word with your webhost regarding this, and ask them to assist you in setting the PHP version for your WebSite X5 project to version 5.6 or above.

The setting in cPanel is a global setting, which can be overridden by other settings on the server/hosting.

The only other possibility is that you have more than one webhosting account, and have mistakenly adjusted the settings on the wrong one?  Your website appears to be hosted by Bluehost...  is that correct?  Did you use your Bluehost cPanel account?

Читать больше
Размещено От Paul M.
Larry H.
Larry H.
User
Автор

Paul, I did finally have to contact Hostgator support and at this point in time, it appears they were able to fix this issue with the website form/php issue. So to anyone else out there, if you are using Hostgator and having trouble with your forms, call them.

To Paul and Aleksej H, thank you for your help. To me a website without a form is worthless. 

Читать больше
Размещено От Larry H.
Paul M.
Paul M.
Moderator

Good to know it's now sorted, Larry...  thanks for the feedback.

Читать больше
Размещено От Paul M.