Welcome Guest ( Log In | Register)



 
Reply to this topicStart new topic
> Smf: Template Parse Error, HELP ME!!!
karlosantana
post Jan 31 2008, 04:35 PM
Post #1


Advanced Member
*******

Group: [HOSTED]
Posts: 128
Joined: 24-November 07
From: Wales(But I'm not a welsh farmer!)
Member No.: 53,645



QUOTE
Template Parse Error!
There was a problem loading the /Themes/default/index.template.php template or language file. Please check the syntax and try again - remember, single quotes (') often have to be escaped with a slash (\). To see more specific error information from PHP, try accessing the file directly.

You may want to try to refresh this page or use the default theme.

Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in .../Themes/default/index.template.php on line 167
And here's line 166
QUOTE
<td height="24" width="222" valign=middle onMouseOver="java script:taust(this,'#0F363F')" onMouseOut="java script:taust(this,'#202020')"> <a href="#">» Free Web design </a></td>

and 167:
QUOTE
<td height="24" width="222" valign=middle onMouseOver="java script:taust(this,'#0F363F')" onMouseOut="javascript:taust(this,'#202020')"> <a href="#">» Free Money </a></td>

It's hating the bit underlined, it's SMF, can't tell you a lot more really, i'm stumped! if you want to see look here I am really pulling my hair out at this can anyone think what i've done wrong? They both look the same and it's line 167 it doesn't like. huh.gif
Any help is well apreciated!
Go to the top of the page
 
+Quote Post
truefusion
post Jan 31 2008, 09:29 PM
Post #2


Ephesians 6:10-17
Group Icon

Group: [MODERATOR]
Posts: 1,887
Joined: 22-June 05
From: The World of Gentoo
Member No.: 8,528
T17 GFX Crew



QUOTE
remember, single quotes (') often have to be escaped with a slash (\).

I believe this explains everything. In your onmouseover and onmouseout events, you have single quotes in them. Escape them, then refresh the page.
Go to the top of the page
 
+Quote Post
karlosantana
post Jan 31 2008, 10:19 PM
Post #3


Advanced Member
*******

Group: [HOSTED]
Posts: 128
Joined: 24-November 07
From: Wales(But I'm not a welsh farmer!)
Member No.: 53,645



When you say escape what do you mean? do you mean i replace them with a backslash? place a blackslash behind it, or that i simply get rid of them?
Go to the top of the page
 
+Quote Post
sonesay
post Jan 31 2008, 11:34 PM
Post #4


|||[ n00b King ]|||
*********

Group: [HOSTED]
Posts: 670
Joined: 20-June 07
From: Auckland
Member No.: 45,102



lets say you want to use a qoute in a string
CODE
$string = "a double looks like this " ";


the above statement will cause an error because it will expect the double qoute at 'this "' to be the closing end. you need to escape it so it ignores it as a closing end and treats it as a double qoute.

CODE
$string = "a double looks like this \" ";


now string will be

a double looks like this "
Go to the top of the page
 
+Quote Post
karlosantana
post Feb 5 2008, 11:30 AM
Post #5


Advanced Member
*******

Group: [HOSTED]
Posts: 128
Joined: 24-November 07
From: Wales(But I'm not a welsh farmer!)
Member No.: 53,645



ok i will give it a go if it doesn't work ill probably put it in a frame and make it look like my site that way unsure.gif pray for me peeps!
Thanks for your help guys



Ok i really can't do this, its damn fustrating mad.gif It will not work no matter what i do If anyones got any spare time ive attatched a file on this post have a look at it destroy it if you wish but anything is appreciated.

If anyone does help me i will give out credits to them (thats how much i will appreciate it!) leave me build up a load of credits (ill post a couple of tutorials) and i will give the person the most i can!
Attached File(s)
Attached File  index.template.php ( 28.27k ) Number of downloads: 3
 
Go to the top of the page
 
+Quote Post
truefusion
post Feb 8 2008, 03:16 PM
Post #6


Ephesians 6:10-17
Group Icon

Group: [MODERATOR]
Posts: 1,887
Joined: 22-June 05
From: The World of Gentoo
Member No.: 8,528
T17 GFX Crew



QUOTE(karlosantana @ Feb 5 2008, 06:30 AM) *
...If anyones got any spare time, i've attatched a file on this post have a look at it, destroy it if you wish, but anything is appreciated.

I'm not sure if the PHP file you attached was the original or modified one, but i'm attaching a modified one with escaped single quotes.

Attached File  index.template.php ( 28.32k ) Number of downloads: 2


If it doesn't work now, then i don't know what's wrong with it. But i recommend editing your files in an editor that supports syntax highlighting. I'd recommend Geany.
Go to the top of the page
 
+Quote Post
karlosantana
post Feb 10 2008, 10:24 AM
Post #7


Advanced Member
*******

Group: [HOSTED]
Posts: 128
Joined: 24-November 07
From: Wales(But I'm not a welsh farmer!)
Member No.: 53,645



okie dokie i will give this a try right now. *uploads file* That geany program is awesome!
Thankyou so much true fusion, you're better than the person who designed the templating system for smf in the first place! Your right though i did put the wrong template up *strangles himself* Hopefully geany should help me though, I will be building my credits up and giving them to you soon, hold in there! I have no idea what happened to the template file i made, its gone ohmy.gif who knows where? Thankyou for putting all that work in though! it is incredibly appreciated! I'm gonna try out this tutorial and see what happens sad.gif although i have done it before with no success, it's worth a try!

I also love some of the things in you sigy
QUOTE
I cannot imagine how the clockwork of the universe can exist without a Clockmaker. (Voltaire)
That is fantastic!
QUOTE
It is said energy cannot be created, nor destroyed. Yet, energy exists. This sounds like God to me!
And so is that!
Thanks again
^^^needs a hug sad.gif
Go to the top of the page
 
+Quote Post
truefusion
post Feb 10 2008, 05:07 PM
Post #8


Ephesians 6:10-17
Group Icon

Group: [MODERATOR]
Posts: 1,887
Joined: 22-June 05
From: The World of Gentoo
Member No.: 8,528
T17 GFX Crew



QUOTE(karlosantana @ Feb 10 2008, 05:24 AM) *
I will be building my credits up and giving them to you soon, hold in there!

I'm not interested in receiving credits. Thanks for the offer, but i didn't help 'cause there was a credit reward. And good luck with that tutorial.
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic

Collapse

> Similar Topics

Topics Topics
  1. Custom Error Pages.(13)
  2. Templates(10)
  3. Wordpress 1.5.1 Installation Problem(7)
  4. Need Some Help With My Template(12)
  5. Joomla Cms Portal(6)
  6. Trap17 Free Web Template Downloads(10)
  7. Website Template!(8)