TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,966
  • Latest: safir45
Stats
  • Total Posts: 195,982
  • Total Topics: 21,320
  • Online today: 1,186
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 1
  • Guests: 521
  • Total: 522
  • illori

boardurl errors

Started by whoesa, May 18, 2006, 07:49:50 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

whoesa

Yes it's the same code without the global $boardurl;
I tried to add it but still give me errors.

I think it has something to do with 1 more code i had to change in index.template.php

Replace this:
else
     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>';


with this
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>';
}


The problem here is that i don't find the exact same code, so i didn't do it.
Because im not sure where and how.  :) I only find this.
// Otherwise, they might want to [logout]...
if ($context['user']['is_logged'])
echo ($current_action == 'logout' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
<td valign="top" class="maintab_' , $current_action == 'logout' ? 'active_back' : 'back' , '">
<a href="', $scripturl, '?action=logout;sesc=', $context['session_id'], '">' , $txt[108] , '</a>
</td>' , $current_action == 'logout' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' : '';


So i quess this is the problem.



IchBin

Is there a $boardurl global variable in SMF? I thought it was $scripturl. Why don't you just take out the global and put the actual URL instead? That should solve it.

whoesa

Well thanks, i did what you told me and it seems to work  ;D

To make sure i did it like it should be, i will tell what i did.

I replaced this:
// Otherwise, they might want to [logout]...
if ($context['user']['is_logged'])
echo ($current_action == 'logout' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
<td valign="top" class="maintab_' , $current_action == 'logout' ? 'active_back' : 'back' , '">
<a href="', $scripturl, '?action=logout;sesc=', $context['session_id'], '">' , $txt[108] , '</a>
</td>' , $current_action == 'logout' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' : '';


with this:
// Otherwise, they might want to [logout]...
if ($context['user']['is_logged'])
echo ($current_action == 'logout' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
<td valign="top" class="maintab_' , $current_action == 'logout' ? 'active_back' : 'back' , '">
                              echo '<a href="http://www.forecaddiebuddies.net/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                                                           

                              <a href="', $scripturl, '?action=logout;sesc=', $context['session_id'], '">' , $txt[108] , '</a>
</td>' , $current_action == 'logout' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' : '';


Is it like it supposed to be?
Just making sure  :)

IchBin


This website is proudly hosted on Crocweb Cloud Website Hosting.