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.

Wordpress website does not work!!! Some error about Gravity Forms, can't log in

  1. My business website is not even showing up, and I can't go in to try to fix it, i don't know what I did!! The website was great before. Here is the message:

    Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /homepages/36/d228295392/htdocs/wsb4753608401/wp-content/plugins/gravityforms/gravityforms.php on line 46

    The website is http://www.dynamicdogschicago.com
    Thanks

    Posted 11 years ago on Monday December 27, 2010 | Permalink
  2. ssteinerX
    Member

    Line 46, in the version I just downloaded, is a blank line after a check to see whether IS_ADMIN is defined. Unless your file's been damaged, there shouldn't be any problem there.

    Any chance there's a syntax error in some piece of PHP above gravityforms in the site's code?

    Sometimes PHP errors trickle down and the error only gets caught later in an unrelated piece of code.

    S

    Posted 11 years ago on Monday December 27, 2010 | Permalink
  3. This error happens because of a PHP version conflict.

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

    Gravity Forms requires PHP5+ and judging from this error you are probably trying to activate the plugin on a site running PHP4. Check with your web host and make sure you have PHP5 enabled.

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

    http://forum.gravityhelp.com/search.php?q=unexpected+T_STRING

    If you're having problems viewing the rest of the site, you may have to FTP into your directory and manually remove the Gravity Forms folder to get rid of the error and restore the site.

    Once everything is restored, you can download the "Requirements Check" plugin from the page linked below and it will tell you if your hosting environment is correct to support Gravity Forms.

    http://www.gravityforms.com/purchase-gravity-forms/

    If not, you can work with your web host to get your PHP version, etc upgraded.

    Posted 11 years ago on Monday December 27, 2010 | Permalink
  4. ssteinerX
    Member

    Actually, now that I look at that code, is it possible that you forgot to close the quote when you edited the file to put in your gf_license_key?

    S

    Posted 11 years ago on Monday December 27, 2010 | Permalink
  5. ssteinerX
    Member

    Would it be possible to get a version check inserted into the code to prevent/nicely catch this error?

    S

    Posted 11 years ago on Monday December 27, 2010 | Permalink
  6. @ssteinerX this is a common error.

    reference: http://forum.gravityhelp.com/search.php?q=t_string

    Gravity Forms requires PHP 5+ to function properly and this error is because the site is using an older version of PHP. There's not really anything else that needs to be debugged at this point. As I mentioned in my previous post, the best course of action is to ftp into the site and manually remove the Gravity Forms folder from the plugin directory to get everything restored to normal.

    Posted 11 years ago on Monday December 27, 2010 | Permalink
  7. @Jennifer,

    I also noticed you're running an old version of Gravity Forms - at least 3 or 4 releases back. When you do get up and running, we recommend that you always run the latest stable release of the plugin so you have all the latest functionality, bug fixes, enhancements, etc.

    Posted 11 years ago on Monday December 27, 2010 | Permalink
  8. ssteinerX
    Member

    @Kevin,

    Yikes, I guess it is!

    This was actually my first visit here...I bought a developer license an hour or so ago.

    I'm a (very) old programmer and saw someone panicking so I tried to help as much as I could with very little information.

    Didn't mean to step on any toes and sure didn't expect anyone from support to be right there with the calm, correct answer. That was kind of amazing actually.

    Hopefully @Jennifer will be able to sort it out in the AM. Friends don't let friends run PHP 4...and neither should hosting companies.

    S

    Posted 11 years ago on Monday December 27, 2010 | Permalink
  9. @ssteinerX No worries and please don't get the wrong idea, we really appreciate members who are willing to help out. Thanks for that.

    This just happens to be something really common so I already knew exactly what it was.

    Posted 11 years ago on Monday December 27, 2010 | Permalink
  10. @Jennifer - on 1&1 hosting, you can add this to the .htaccess file in the root of your WordPress install, to force all php files to be served as PHP5:

    AddType x-mapp-php5 .php

    Add that as the first line of the .htaccess file and all will be well.

    Posted 11 years ago on Tuesday December 28, 2010 | Permalink