View Single Post
  #21  
Old 03-25-2014, 04:35 AM
 
kdw kdw is offline
 

Member
  
Join Date: Oct 2011
Posts: 17
 

Default Re: Load different style sheets for main categories

Hi again
I have
{if $topId eq 52}
{load_defer file="css/shoes.css" type="css"}
{/if}
in service_css.tpl
and
{elseif $topId eq 52}
<img src="{$AltImagesDir}/schools/school_shoes.png" alt="" />
in head.tpl


Works fine.
This changes the styles in the product pages too which is what is needed.
Now I need to do the same for a sub category?
Have different styles and main logo for different sub cats.

I can use if $catid and styles change when I go to that category page BUT when I then click on a product the style reverts to the main category style.
Can anyone advise what to use so that the sub cat style is maintained as long as it is when using if $topid ie. through cat pages, product listing pages and product details page.

Assuming this is possible of course!


Thanks
__________________
tech990
Reply With Quote