Jump to content


Parse error: syntax error, unexpected T_STRING

  • Please log in to reply
2 replies to this topic

#1 zghayes

  • New Members
  • Pip
  • Newbie
  • 2 posts

Posted 03 July 2006 - 03:46 AM

Hi all

I'm a PHP & MySQL newbie and could use some help with an error that seems to have appeared out of nowhere on my website.

Here is a link to the site:  www.mr-sparkle.com

I'm using WordPress with Gallery 2 embedded.

The WordPress fuctionality of my site has no problems, it's somethng wrong with G2.  The site was having no issues and then yesterday, without me changing anything, this error popped up:

Parse error: syntax error, unexpected T_STRING in /home/zghayes/public_html/gallery2/main.php on line 115

I've attached the main.php file for my site with the hope that someone here will be kind enough to help me out.  My site is mainly for sharing pictures with family, and my wife and I just had a baby daughter a couple weeks ago, so needless to say this outage is causing a lot of complaints from relatives.

Thanks in advance!

[attachment deleted by admin]

#2 .josh

  • Staff Alumni
  • .josh
  • 14,871 posts

Posted 03 July 2006 - 03:52 AM

in your code here:
print '<h1> Debug Redirect </h1>' .
'Not automatically redirecting you to the next page because we\'re in debug mode';<br>
you need to escape the ' in your we're (notice the \ before it)
Did I help you? Feeling generous? Buy me lunch! 
Please, take the time and do some research and find out how much it would have cost you to get your help from a decent paid-for source. A "roll-of-the-dice" freelancer will charge you $5-$15/hr. A decent entry level freelancer will charge you around $15-30/hr. A professional will charge you anywhere from $50-$100/hr. An agency will charge anywhere from $100-$250/hr. Think about all this when soliciting for help here. Think about how much money you are making from the work you are asking for help on. No, we do not expect you to pay for the help given here, but donating a few bucks is a fraction of the cost of what you would have paid, shows your appreciation, helps motivate people to keep offering help without the pricetag, and helps make this a higher quality free-help community :)

#3 zghayes

  • New Members
  • Pip
  • Newbie
  • 2 posts

Posted 03 July 2006 - 01:44 PM

Thanks for the quick reply, that problem is fixed..

Turns out though that somehow the entire file was corrupted.  I downloaded the main.php file from the Gallery 2 installer and it was 600+ lines of code vs my file which was 230ish.  After further inspection that wasn't the only file that happened to.  Looks like I'm spending part of the day reinstalling Gallery...

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users