Advertisement:

Author Topic: Template Parse Error!  (Read 3746 times)

Offline GN/Henny

  • Jr. Member
  • **
  • Posts: 107
Template Parse Error!
« on: February 28, 2012, 04:07:13 AM »
My forum runs now for many years, and yesterday there is a problem.
I didn't do anything at the forum, and now I don't know what to do, who can help me??

http://www.kellyfamily.nl/forum/
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.
syntax error, unexpected T_ELSE

Offline mashby

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 8,394
  • Gender: Male
  • badass beer hound
    • Choppix
Re: Template Parse Error!
« Reply #1 on: February 28, 2012, 06:43:18 AM »
Can you download via FTP this file:
Themes/default/index.template.php
And attach it in a reply?
Always be a little kinder than necessary.
- James M. Barrie

Offline GN/Henny

  • Jr. Member
  • **
  • Posts: 107
Re: Template Parse Error!
« Reply #2 on: February 28, 2012, 07:33:42 AM »
here it is

Offline CapadY

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 3,151
  • Gender: Male
Re: Template Parse Error!
« Reply #3 on: February 28, 2012, 07:54:32 AM »
Whats your SMF version ? It is always fine to know with which file-version it should be compared.
Please, don't PM me for support unless invited.
If you don't understand this, you will be blacklisted.

Offline CapadY

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 3,151
  • Gender: Male
Re: Template Parse Error!
« Reply #4 on: February 28, 2012, 08:00:00 AM »
This index.template is for SMF1.1.5, are you sure that's correct ?

I'm asking this because this is the SMF2 support board.
Please, don't PM me for support unless invited.
If you don't understand this, you will be blacklisted.

Offline GN/Henny

  • Jr. Member
  • **
  • Posts: 107
Re: Template Parse Error!
« Reply #5 on: February 28, 2012, 08:12:38 AM »
oi,
I don't know for sure, I had the latest update, because I always do that.
Can I check that?

Offline GN/Henny

  • Jr. Member
  • **
  • Posts: 107
Re: Template Parse Error!
« Reply #6 on: February 28, 2012, 08:27:02 AM »
I think that I have to transfer this topic to the other board?

Offline CapadY

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 3,151
  • Gender: Male
Re: Template Parse Error!
« Reply #7 on: February 28, 2012, 08:41:00 AM »
I think that I have to transfer this topic to the other board?

You can't do that yourself.

Latest version of the SMF1.x branch is 1.1.16 but maybe this file isn't touched with the latest upgrade.

I think the best thing you can do is renaming this particular file to index.template_org.php or something like that, download a fresh one from the download section and replace it by the fresh one.

If you are loosed MOD functionality that can be solved later.
Please, don't PM me for support unless invited.
If you don't understand this, you will be blacklisted.

Offline mashby

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 8,394
  • Gender: Male
  • badass beer hound
    • Choppix
Re: Template Parse Error!
« Reply #8 on: February 28, 2012, 09:03:38 AM »
Line 604 seems to have an echo statement missing. Not sure if this will make it ALL better, but it's a start.

In fact, the entire Logout section just seems odd to me. Looks like the flashchat button isn't inserted quite correctly not only in placement, but in format:
Code: [Select]
// Otherwise, they might want to [logout]...
if ($context['user']['is_logged'])
else {
     echo '<a href="', $GLOBALS['boardurl'], '/chat/flashchat.php">',
     ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url']
     . '/chat_icon.gif" alt="FlashChat" style="margin: 2px 0;"
     border="0" />' : "FlashChat"),'</a>';

    echo '<a href="', $scripturl, '?action=logout;sesc=', $context['session_id'],
    '">', ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url']
    . '/' . $context['user']['language'] . '/logout.gif" alt="' . $txt[108]
    . '" style="margin: 2px 0;" border="0" />' : $txt[108]),'</a>';
}
echo '
</td>' , $current_action == 'logout' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' : '';
Always be a little kinder than necessary.
- James M. Barrie

Offline GN/Henny

  • Jr. Member
  • **
  • Posts: 107
Re: Template Parse Error!
« Reply #9 on: February 28, 2012, 09:23:55 AM »
the att. did you change that? or is it the same old one, I uploaded? I thied it, but didn't work

Offline mashby

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 8,394
  • Gender: Male
  • badass beer hound
    • Choppix
Re: Template Parse Error!
« Reply #10 on: February 28, 2012, 09:35:58 AM »
I changed it somewhat. When did FlashChat get added to your site? That is likely the cause of your current situation. This version has that part removed and the original Logout code inserted. This should work, but not entirely sure. :)
Always be a little kinder than necessary.
- James M. Barrie

Offline GN/Henny

  • Jr. Member
  • **
  • Posts: 107
Re: Template Parse Error!
« Reply #11 on: February 28, 2012, 09:44:09 AM »
that was installed for 5 or 6 years, I'll try this one

Offline GN/Henny

  • Jr. Member
  • **
  • Posts: 107
Re: Template Parse Error!
« Reply #12 on: February 28, 2012, 09:47:56 AM »
yes this works, but I have now the default theme
when I click on a link ( topic or what ever) I get the notice that it's not the correct derectory, and that I have to click it ( the notice) and it comes everytime back

Offline mashby

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 8,394
  • Gender: Male
  • badass beer hound
    • Choppix
Re: Template Parse Error!
« Reply #13 on: February 28, 2012, 08:45:23 PM »
Did you have another theme running then? I see your site is on the default theme at the moment. I'm thinking you had another theme that went sour, but your error message seemed to say otherwise.
Always be a little kinder than necessary.
- James M. Barrie

Offline GN/Henny

  • Jr. Member
  • **
  • Posts: 107
Re: Template Parse Error!
« Reply #14 on: February 29, 2012, 04:12:38 AM »
yes that was the default theme, but when I put the theme in the directory, instead of default, it looks allmost ok.

this directorys are they ok?

/customers/kellyfamily.nl/kellyfamily.nl/httpd.www/forum/Smileys

/customers/kellyfamily.nl/kellyfamily.nl/httpd.www/forum/Themes/helios1.1

kat

  • Guest
Re: Template Parse Error!
« Reply #15 on: February 29, 2012, 08:58:07 AM »
Is the "httpd" correct?

I know what is it, but I've never seen it on a website, thus far.

Offline Illori

  • Project Manager
  • SMF Master
  • *
  • Posts: 49,448
Re: Template Parse Error!
« Reply #16 on: February 29, 2012, 08:59:37 AM »
httpd is another name for the apache service, and that folder can be whatever the host wants to name it, just usually it is www, or http or similar.

but as we dont know your server configuration we cant really tell if the path is correct, your host would know though.

kat

  • Guest
Re: Template Parse Error!
« Reply #17 on: February 29, 2012, 09:05:46 AM »
Oh, yeah. As I said, I know what it is.

Just seemed weird, seeing it there, like that.

Thought it worth checking. :P