WordPress.org

Forums

[resolved] Parse Error with OPTION.PHP file (11 posts)

  1. wolfdenptsa
    Member
    Posted 3 years ago #

    My website home page produces the following message :
    Parse error: syntax error, unexpected T_VARIABLE in /home/(my web)/public_html/wp/wp-includes/option.php on line 225

    I get the same error message when I try to login as the Admin.

    I am running WordPress 3.4. Everything was fine a few days ago - I changed nothing! I also re-uploaded a fresh copy of option.php. No change.

  2. wolfdenptsa
    Member
    Posted 3 years ago #

    Sorry - forgot to include that I'm running PHP version 5.2.17

  3. gulliver
    Member
    Posted 3 years ago #

    I have a similar issue - things were working fine, then overnight this problem arose.

    A check shows that the server version of option.php is identical to the downloaded original.

    Update: a further check suggests this is an issue with my server host - other sites of mine are showing messages of 'Your server is running PHP version 4.4.9 but WordPress 3.3.2 requires at least 5.2.4.' - so that suggests the cause of my problem is non-WP.

  4. wolfdenptsa
    Member
    Posted 3 years ago #

    Problem fixed. For some reason my host provider disabled PHP - why I have no idea ....

  5. humbucker
    Member
    Posted 3 years ago #

    Guys, if you entounter this problem,
    be sure your server is running PHP5.

    Otherwise, enable it yourselves by adding a .htaccess file in your directory that contains this string : SetEnv PHP_VER 5

    Do not edit your WordPress core files! ;)

  6. benjancewicz
    Member
    Posted 3 years ago #

    Thanks humbucker, that solved my issue too!

  7. damdo74
    Member
    Posted 3 years ago #

    Hi all,
    even after setting up an .htaccess file with the string : SetEnv PHP_VER 5
    I still encouter the error : Parse error: syntax error, unexpected T_VARIABLE in /homepages/25/d314414797/htdocs/wp-includes/option.php on line 225

    I called my hosting provider 1&1 and they won't give me any kind of support on this.

    Can anyone point me toward solutions ?

    I appreciate.
    Thanks

  8. kaskelinefilmacademy
    Member
    Posted 3 years ago #

    Hi damdo74,

    i had the same problem with the same hoster. you have to log in to 1und1 and open "globale php-version". there you have the choice between php 4, php 5 and php dev.

    i first set it to php 5 and it didn't help. if you set it to php dev everything should work.

    i assume 1und1 categorizes all versions above 5.0 as dev.

    hope this helps, markus

  9. damdo74
    Member
    Posted 3 years ago #

    Thanks a lot Markus,
    it did solve my problem.
    It's a shame no one at the 1&1 hotline did not point me toward it.

  10. Colour Infusion
    Member
    Posted 3 years ago #

    Thanks! Setting the server to PHP-5 solved the issue for me!

  11. stollo
    Member
    Posted 3 years ago #

    Thank you kaskelinefilmacademy, solved my problem and saved me a few hours of research!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.