lasseboy Posted February 12, 2013 Share Posted February 12, 2013 Is it possible to make Kategori tree link go directly to page... not to page with subcategories. Hope you get what i meen! Link to comment Share on other sites More sharing options...
vekia Posted February 12, 2013 Share Posted February 12, 2013 i don't understand well haha, when you click on category link - you will se category page, so isn't it correct? Link to comment Share on other sites More sharing options...
lasseboy Posted February 12, 2013 Author Share Posted February 12, 2013 Well if you go here http://www2.gedetvidare.nu/index.php klick on BÖCKER now it will redirect you to a page will all subcategories for BÖCKER. But i want the link just to open all subgategoires in kategori tree. Link to comment Share on other sites More sharing options...
vekia Posted February 12, 2013 Share Posted February 12, 2013 ok, now i probably understand after click on category you want to roll out subcategories in categories tree, like below: so ad I said you don't want to open category page, just to roll out categories in tree, am I right? you must modify block categories module (js + smarty code probably) 1 Link to comment Share on other sites More sharing options...
lasseboy Posted February 12, 2013 Author Share Posted February 12, 2013 Yes thats what i want!! i will try to do that.... thanks! Link to comment Share on other sites More sharing options...
lasseboy Posted February 12, 2013 Author Share Posted February 12, 2013 Did you meen blockcategories.php cant find blockcategories.js Link to comment Share on other sites More sharing options...
vekia Posted February 12, 2013 Share Posted February 12, 2013 check .tpl files of this module Link to comment Share on other sites More sharing options...
lasseboy Posted February 12, 2013 Author Share Posted February 12, 2013 MM only thing in root/ modules/blockcategories/ blockcategories.tpl is this code: <!-- Block categories module --> <div id="categories_block_left" class="block"> <p class="title_block">{l s='Categories' mod='blockcategories'}</p> <div class="block_content"> <ul class="tree {if $isDhtml}dhtml{/if}"> {foreach from=$blockCategTree.children item=child name=blockCategTree} {if $smarty.foreach.blockCategTree.last} {include file="$branche_tpl_path" node=$child last='true'} {else} {include file="$branche_tpl_path" node=$child} {/if} {/foreach} </ul> {* Javascript moved here to fix bug #PSCFI-151 *} <script type="text/javascript"> // <![CDATA[ // we hide the tree only if JavaScript is activated $('div#categories_block_left ul.dhtml').hide(); // ]]> </script> </div> </div> <!-- /Block categories module --> Link to comment Share on other sites More sharing options...
PascalVG Posted February 12, 2013 Share Posted February 12, 2013 (edited) Hi Lasseboy, Tree management of the categories is done in a .js file, located in your theme-folder: /themes/<your theme folder>/js/tools/treeManagement.js I'll have a quick look if I can find what to change. Give it a try yourself as well :-) Pascal Edited February 12, 2013 by PascalVG (see edit history) 1 Link to comment Share on other sites More sharing options...
vekia Posted February 12, 2013 Share Posted February 12, 2013 you must edit branche tpl file by adding condition: "if category is main category" - if so, - remove <a href> from it and add simple action onclick="". You have to add in onclick function to rollout subcategories, exactly as @PascalVG said , script for this module is located in theme folder Link to comment Share on other sites More sharing options...
lasseboy Posted February 12, 2013 Author Share Posted February 12, 2013 MM this was moore then my litle brain could fix!! Link to comment Share on other sites More sharing options...
lasseboy Posted February 18, 2013 Author Share Posted February 18, 2013 Sorry ! Cant fix this, is it easyer to change Template with this function included? Link to comment Share on other sites More sharing options...
Recommended Posts