SimplePortal

Customization => Themes and Graphics => Topic started by: The Chief on February 07, 2013, 12:24:41 PM

Title: Custom Theme "Home Button"
Post by: The Chief on February 07, 2013, 12:24:41 PM
I am having trouble making my Custom Theme HOME Button work, I have tried all the variations I could think of but my custom Theme is not Liking the Portal. This all occurred when I updated to SMF 1.1.18 ad then upgraded too SP 2.3.5. I didn't even realize it for a few weeks until a member told me.

My Custom Theme uses the Following Code for the Home Button (index.template.php):

Code: [Select]
// Show the [home] button.
echo '
<li><a class="nav" href="', $scripturl, '?action=home"><span>' , $txt[103] , '</span></a></li>';

Here is the Simple Portal Home button so members can be directed to the Portal from the Forum:

Code: [Select]
// Show the [home] button.
echo ($current_action=='home' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
<td valign="top" class="maintab_' , $current_action == 'home' ? 'active_back' : 'back' , '">
<a href="', ($modSettings['sp_portal_mode'] == 3 && empty($context['disable_sp']) ? $modSettings['sp_standalone_url'] : $scripturl), '">' , $txt[103] , '</a>
</td>' , $current_action == 'home' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' : '';

This code obviously works but not in the same CSS Styling.

Can anyone assist me in getting the right code I have been going crazy.


Site is www.forums.midatlanticxriders.com




Title: Re: Custom Theme "Home Button"
Post by: The Chief on February 14, 2013, 08:36:25 AM
Ouch - 138 Views NADA!
Title: Re: Custom Theme "Home Button"
Post by: xKroniK13x on February 15, 2013, 12:01:17 AM
You should be able to edit the Subs.php file in the Sources directory. There will be an array of all of the menubar buttons in there... just add it to the list. Most themes should read the buttons straight from this file.
Title: Re: Custom Theme "Home Button"
Post by: The Chief on February 18, 2013, 01:23:15 PM
I will give er a shot!
Title: Re: Custom Theme "Home Button"
Post by: phantomm on February 18, 2013, 02:39:48 PM
Menu is inside Subs.php since SMF 2.0.
For SMF 1.1 you need to edit every index.template.php file, but i have no idea how to edit this file to make it work :|
Title: Re: Custom Theme "Home Button"
Post by: AngelinaBelle on June 18, 2013, 07:36:46 AM
For your custom SMF 1.1.X theme, you will need to edit the index.template.php file after SimplePortal is done with it. 

1) replace the <td> with <li> and the </td> with </li>.
2) Make the styling the way you want it to go -- using the class=nav styling from your theme
3) Check that SimplePortal changed your old "home" button to be a "forum" button, to point to your forum, instead of to your portal page.

Good luck!

SimplePortal 2.3.8 © 2008-2024, SimplePortal