Huge technical problem to do with wordpress

by 20 replies
23
I have a site that I changed part of the code in and now I cannot log back into at this always comes up:

Parse error: syntax error, unexpected T_CLASS in /home/tom/public_html/homemade-solar-panel.org/wp-content/themes/my-theme-with-grass-and-dew/functions.php on line 75

Im really worried as I do not know what to do. If it helps the site is: homemade-solar-panel.org

Does anyone know what to do? Can I delete wordpress and re install it? I am on hostgator hosting if that helps.

Thanks so much to anyone who knows what to do or a link to something, I have been looking for hours.
#website design #huge #problem #technical #wordpress
  • You can try to delete the theme you have installed through your ftp client or file explorer in hostgator. That might get you back in to the dashboard to reinstall the theme.
  • I cannot even log into wordpress Cp and could you explain how to do that in hostgator?
  • Should I delete the add on domain from hostgator and then re add it and re install wordpress, would that work?
  • If you can't log back in as admin... the best way is to remake the whole thing.. start from scratch, I guess... You can do it from your your host's side.
  • There are two ways you can fix this. You will need to log into your hosting account Cpanel. Go into the File manager and then into public html. Next, go homemade-solar-panel.org/wp-content/themes/my-theme-with-grass-and-dew/

    You can then either re-upload the file functions.php file (if you have a copy prior to editing) or you can click on Code editor and edit the file yourself. You will need to go down to line 75 in the code and adjust.

    Without seeing the code, you are probably missing some quotation marks or something like that.
    • [ 1 ] Thanks
  • You say you changed the code - what code? Was it in the Wordpress coding, or the theme?
  • Just download a fresh copy of your theme. Unzip and upload the functions.php file to wp-content>themes>(your theme).
    • [1] reply
    • Theme code I thought but perhaps not

      Thanks for the information everyone.
      I think I have sorted it out, or should be in 10.

      Thanks again.
  • Log into the server with an FTP client and delete the theme.

    Wordpress should then revert back to the 2010 or 2011 theme.


    Pro tip:

    Before you make changes to a theme make a backup, just download the theme to your computer.

    If something goes wrong, upload the backup and overwrite your changes.
    • [ 1 ] Thanks
  • Hi Tom
    Glad you sorted it out, just wanted to say it's nice to see another Taffy on here
    I'm from Ammanford the other side of Swansea.
    All the best with your venture
    Elaine
  • this is a minor PHP error probably, PM me and i'll give you my email address - send the file to me and i'll have a look
  • Banned
    This has sometimes worked for me. Download via filezilla or some other program, the functions.php file in your theme folder. Scroll to the end and right after the last piece of php code, delete all remaining white space. Just put your cursor after the last character and hit delete numerous times. Then save it and reupload it.
    • [ 1 ] Thanks
    • [1] reply
    • errors like that cannot possibly be produced by whitespace, so removing it won't make any difference. it must be something else you have done to fix.
      • [2] replies
  • Parse error: syntax error, unexpected T_CLASS in /home/tom/public_html/homemade-solar-panel.org/wp-content/themes/my-theme-with-grass-and-dew/functions.php on line 75

    The answer is in the question itself, look at line 75..if you dont understand anything google it or post that line here..
    • [1] reply
    • A T_Class can occurr earlier do to a brace being opened so the line # can be very misleading. It is a place to start but certainly not a definite answer.
      • [1] reply
  • I encountered a similar problem when I uploaded my niche site and I could just not get it fixed. I was also advised to restart the whole thing (remove the domain from the host and start from scratch). Sigh!

Next Topics on Trending Feed

  • 23

    I have a site that I changed part of the code in and now I cannot log back into at this always comes up: Parse error: syntax error, unexpected T_CLASS in /home/tom/public_html/homemade-solar-panel.org/wp-content/themes/my-theme-with-grass-and-dew/functions.php on line 75