SimplePortal

Support => English Support => Topic started by: ScottDB on August 02, 2009, 05:03:57 PM

Title: can not load posts
Post by: ScottDB on August 02, 2009, 05:03:57 PM
Hi, I am trying to get add as an article to work in my Helios_multi theme. I have it working in all my other themes but can't get this one. Every time I click on a post I get the following error message:
  Template Parse Error! It seems something has gone sour on the forum with the template system. This problem should only be temporary, so please come back later and try again. If you continue to see this message, please contact the administrator.

Had someone help me out and got this. Had the same error message when I tried it. Can someone help me out please. Have posted it here and in SMF but no help.
Title: Re: can not load posts
Post by: ccbtimewiz on August 02, 2009, 05:39:37 PM
That theme builds the button array using the variable $buttonArray[]

Loading into that would fix the issue you're having.

Find and remove:
Code: [Select]
        // Make Article Button
if ($context['can_make_article'])
$normal_buttons['article'] = array('text' => 'sp-make_article', 'image' => 'addarticle.gif', 'lang' => true, 'url' => $context['portal_url'] . '?sa=addarticle;message=' . $context['topic_first_message'] . ';return=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id']);

Find:
Code: [Select]
        if ($context['can_reply'])
                $buttonArray[] = '<a href="' . $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies'] . '">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/reply.gif" alt="' . $txt[146] . '" border="0" />' : $txt[146]) . '</a>';

Replace with:
Code: [Select]
        if ($context['can_reply'])
                $buttonArray[] = '<a href="' . $scripturl . '?action=post;topic=' . $context['current_topic'] . '.' . $context['start'] . ';num_replies=' . $context['num_replies'] . '">' . ($settings['use_image_buttons'] ? '<img src="' . $settings['images_url'] . '/' . $context['user']['language'] . '/reply.gif" alt="' . $txt[146] . '" border="0" />' : $txt[146]) . '</a>';

if ($context['can_make_article'])
$buttonArray[] = '<a href="' . $context['portal_url'] . '?sa=addarticle;message=' . $context['topic_first_message'] . ';return=' . $context['current_topic'] . '.' . $context['start'] . ';sesc=' . $context['session_id'] . '">'  . $txt['sp-make_article'] . '</a>';
Title: Re: can not load posts
Post by: ccbtimewiz on August 02, 2009, 06:23:28 PM
Sorry, I should have been specific-- do both.
Title: Re: can not load posts
Post by: [SiNaN] on August 09, 2009, 11:50:34 AM
Is this issue solved ScottDB?
SimplePortal 2.3.8 © 2008-2024, SimplePortal