X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Highlight current page in speedbar (https://forum.x-cart.com/showthread.php?t=53581)

cflsystems 05-24-2010 08:27 AM

Re: Highlight current page in speedbar
 
{if $current_category.categoryid eq "xxx" || $current_category.parentid eq "xxx"} class="current"{/if}
Not sure on top of my head if it's "parent", "parentid", or "paren_category"

FTI 05-24-2010 11:04 AM

Re: Highlight current page in speedbar
 
Thanks, again Steve. This was extremely helpful, is there any way this to be done for the sub-sub categories without writing a whole bunch of numbers?

Take a look

cflsystems 05-24-2010 12:49 PM

Re: Highlight current page in speedbar
 
Not sure but there is probably a way

ARW VISIONS 05-24-2010 12:59 PM

Re: Highlight current page in speedbar
 
{if $current_category.categoryid_path|regex_replace:" /\/[0-9\/]*/":""}class="current"{/if}

This should work

FTI 05-24-2010 02:38 PM

Re: Highlight current page in speedbar
 
Thanks Ash, where to put the category ID?

ARW VISIONS 05-24-2010 05:09 PM

Re: Highlight current page in speedbar
 
{if $current_category.categoryid_path|regex_replace:" /\/[0-9\/]*/":"" eq "259"}class="current"{/if}

FTI 05-30-2010 07:57 AM

Re: Highlight current page in speedbar
 
Thaht did a perfect job. Ash, you are awesome. You and Steve, figured out the whole thing for me. Thanks guys! :)

ARW VISIONS 05-30-2010 10:55 AM

Re: Highlight current page in speedbar
 
no problem, glad I could help.

Ajay 06-06-2010 03:25 PM

Re: Highlight current page in speedbar
 
I want to remove the link on the tab, when same page is being viewed. So I made this change to skin1/customer/head.tpl . This is in 4.2.x
Quote:

<div class="tabs">
<ul>
{foreach from=$speed_bar item=sb}
{if $smarty.server.REQUEST_URI|replace:"/shop/":"" eq $sb.link }
<li class="current" >{$sb.title}</li>
{else}
<li><a href="{$sb.link|amp}">{$sb.title}</a></li>
{/if}
{/foreach}
</ul>
</div>


And then you can change the color of .current class as you wish

believein 06-28-2011 02:59 AM

Re: Highlight current page in speedbar
 
Is there a way of doing this to highlight using the page Id for static pages?


All times are GMT -8. The time now is 12:34 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.