PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

Moved to Linux Server, Now Getting An Error

  1. madhatter
    Member

    Hello!

    I switched http://nwwatersystems.com from a Windows to a Linux server yesterday and now I'm getting an error when the Gravity Forms plugin is uploaded to the plugins folder. Here is the error I get:

    Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /home/content/n/w/w/nwwater/html/wp-content/plugins/gravityforms/gravityforms.php on line 74

    This error is when the current version is uploaded. The error below is when the beta version is uploaded.

    Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /home/content/n/w/w/nwwater/html/wp-content/plugins/gravityforms/gravityforms.php on line 74

    I can't leave the plugin in the plugins folder because just having it there makes the entire site show this error and the site needs to be live for my client. Any ideas? Do you need more information from me?

    I moved to a Linux server with hopes that the email notifications would work since they haven't been. Any help is much appreciated. My client is getting very antsy...

    Posted 13 years ago on Thursday February 17, 2011 | Permalink
  2. madhatter
    Member

    Just an update to this:

    I deleted the plugin and then went to the plugins page in the dashboard and saw the "this plugin has been deactivated because it doesn't exist" message. At that point I was able to upload the Gravity Forms folder into the plugins folder without getting an error. However, I just tried to activate the plugin and got the same error, this time telling me the plugin could not be activated due to the error on line 59 that I posted above. So, that's where I am. Thanks!

    Posted 13 years ago on Thursday February 17, 2011 | Permalink
  3. madhatter
    Member

    Uh, sorry, I'm tired and didn't paste the correct error above. The first error should be line 59, the second error, with the beta version, is line 74.

    Posted 13 years ago on Thursday February 17, 2011 | Permalink
  4. This error is the 2nd issue covered in our FAQ here:

    http://www.gravityhelp.com/frequently-asked-questions/

    It is a PHP version error. Gravity Forms requires PHP 5 and you are trying to activate it on a site running PHP 4.

    You need to turn on PHP 5. Contact your web host to find out how to activate it on that site if you are unsure.

    Posted 13 years ago on Thursday February 17, 2011 | Permalink
  5. madhatter
    Member

    Thanks for the reply! GoDaddy says the site is running PHP 5. I'm not sure what I need to do or say to GoDaddy. Thank you!

    Posted 13 years ago on Thursday February 17, 2011 | Permalink
  6. There are instructions here for GoDaddy:

    http://codex.wordpress.org/Switching_to_PHP5#Web_Hosting_PHP_Switch_Examples

    It's a configuration setting in the GoDaddy control panel.

    Posted 13 years ago on Thursday February 17, 2011 | Permalink
  7. madhatter
    Member

    It's already running PHP 5. There is no option to upgrade. And in my hosting control center it says this:

    PHP Version:
    PHP 5.x

    Posted 13 years ago on Thursday February 17, 2011 | Permalink
  8. Sometimes GoDaddy changes take a while to become active. Did you have them change to PHP5, or was it always set to PHP5 on this account?

    Once PHP5 is actually in use for WordPress and Gravity Forms, this error will go away.

    If you put this into a file on the server where your WordPress installation is located (call it info.php)

    <?php
    phpinfo();
    ?>

    Then access it with a browser, http://nwwatersystems.com/info.php you will see the version of PHP that the server is running in that location. Remove the file when you're done checking since it is considered a security risk by some to leave that information accessible.

    Posted 13 years ago on Thursday February 17, 2011 | Permalink
  9. madhatter
    Member

    Interesting. So the file tells me it's running PHP 4.4.9. The hosting control panel has said PHP 5 since the day I switched the server to Linux. So that means it's really not running PHP 5 then?

    Posted 13 years ago on Thursday February 17, 2011 | Permalink
  10. I can tell you with 100% certainty that if you are receiving that error you aren't running PHP 5, no matter what the GoDaddy control panel tells you.

    See @illinoisharley's response above. GoDaddy changes aren't always instant. When you make changes it takes time to take effect. I'm not sure why this is, they don't do things like most hosts.

    Try the simple php version check @illinoisharley's suggests above and place that code on a page and go to that page and it will tell you what version of PHP is active. If you have problems getting PHP 5 working you will need to contact GoDaddy directly.

    Posted 13 years ago on Thursday February 17, 2011 | Permalink
  11. madhatter
    Member

    Yeah, it's definitely running 4.4.9 regardless of what the control panel says. I switched the server on Wednesday. Surely it doesn't take them three days to update?? Either way, I'll put in a call to them this afternoon to let them know what I found. Thanks so much for your help!

    Posted 13 years ago on Thursday February 17, 2011 | Permalink