Jump to content

[Solved] Removing top category linking.


Recommended Posts

Hi.

 

I would like to remove the linking of the top categories when sub categories are present, but still showing the arrow (to the left), and the +(to the right) images.

 

I've tried messing with line 28 in category-tree-branch.tpl, under modules/blockcategories.

 

But I'm not quite sure how to do this.

 

I'm currently using version 1.5.2.

 

Any ideas?

 

- Kris.

 

Edit: First post. :D

Edited by Supremacy2k (see edit history)
Link to comment
Share on other sites

Try changing the line with this:

{if $node.children|@count > 0}{$node.name|escape:'htmlall':'UTF-8'}{else}<a href="{$node.link|escape:'htmlall':'UTF-8'}" {if isset($currentCategoryId) && $node.id == $currentCategoryId}class="selected"{/if} title="{$node.desc|escape:'htmlall':'UTF-8'}">{$node.name|escape:'htmlall':'UTF-8'}</a>{/if}

Link to comment
Share on other sites

Fixed it!

 

changed line 28 in category-tree-branch.tpl to this:

 

<a href="{if $node.children|@count > 0}{else}{$node.link|escape:'htmlall':'UTF-8'}{/if}" {if isset($currentCategoryId) && $node.id == $currentCategoryId}class="selected"{/if} title="{$node.desc|escape:'htmlall':'UTF-8'}">{$node.name|escape:'htmlall':'UTF-8'}</a>

 

That way it will make all top categories with sub categories link to current page/product, and all sub category links remains intact.

 

:D :D

Edited by Supremacy2k (see edit history)
Link to comment
Share on other sites

  • 4 months later...

Hi Supremacy2K,

 

I'm having the same issue. I've followed your instructions. Changed line 28 in category-tree-branch.tpl (theme folder) to the line you posted on message #5, and commented line 33 in blockcategories in root modules folder. I'm still having the same issue, top cathegories have links to non-existing pages. Do you know what could be happening? Maybe a CACHE thing?

 

Thanks!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...