linster Posted April 18, 2014 Share Posted April 18, 2014 Hi, I need to add icons on the side of the category name on the left sidebar. Can someone help guide me how to do it? Product link to refer to: http://www.joshua-thelabel.com/shop/index.php?id_product=8&controller=product&id_lang=1 Link to comment Share on other sites More sharing options...
NemoPS Posted April 18, 2014 Share Posted April 18, 2014 You can only use a workaround. In the categories block, give each like a class like categorylink_*id_category* (you get it from the loop). Then, in your css, apply a background image to each. Otherwise you need to do some really heavy modifications and allow images upload for each one! Link to comment Share on other sites More sharing options...
vekia Posted April 18, 2014 Share Posted April 18, 2014 add class as Nemo suggested: class="category_{$node.id}" in category-tree-branch.tpl code: <li class="category_{$node.id}{if isset($last) && $last == 'true'} last{/if}"> <a href="{$node.link|escape:'html':'UTF-8'}"{if isset($currentCategoryId) && $node.id == $currentCategoryId} class="selected"{/if} title="{$node.desc|strip_tags|trim|escape:'html':'UTF-8'}"> {$node.name|escape:'html':'UTF-8'} </a> {if $node.children|@count > 0} <ul> {foreach from=$node.children item=child name=categoryTreeBranch} {if $smarty.foreach.categoryTreeBranch.last} {include file="$branche_tpl_path" node=$child last='true'} {else} {include file="$branche_tpl_path" node=$child last='false'} {/if} {/foreach} </ul> {/if} </li> btw. you can also use fontawesome, follow steps described here:http://www.prestashop.com/forums/topic/288624-imageicon-in-category-menu/ 1 Link to comment Share on other sites More sharing options...
Recommended Posts