byt Posted October 2, 2009 Share Posted October 2, 2009 Hi,I would like to setup the catergories bar with sub headings:For exampleCatergory <- not clickable but with a backdrop like the presta demoshop 'all new products' button product <- clickable product < - clickableCatergory <-- not clickable but with backdrop like the presta demoshop 'all new products' button product product productCatergoryIm sure you get the idea, how can I do this? what files do I need to edit?Thanks guys, hope someone will be kind enough to help! Link to comment Share on other sites More sharing options...
byt Posted October 3, 2009 Author Share Posted October 3, 2009 Anybody? this can't be unique? To give an idea heres a picture of what Im looking forhttp://img16.imageshack.us/img16/6274/examplecx.jpgReally hope someone can help Cheers! Link to comment Share on other sites More sharing options...
glenns Posted May 17, 2010 Share Posted May 17, 2010 Hey all, sorry to bump this up but I am wondering the same thing, and more importantly how do I change around the listing in the categories block? When I add a new category it lists everything alphabetically, how do I change the order of how they appear?THANKS!! Link to comment Share on other sites More sharing options...
rocky Posted May 17, 2010 Share Posted May 17, 2010 You can change the order of categories by prefixing them with a number then a period. For example, "01.First Category", "02.Second Category", etc.To display the first level of categories with headings instead of links, change lines 9-13 of modules/blockcategories/blockcategories.tpl from: {if $smarty.foreach.blockCategTree.last} {include file=$branche_tpl_path node=$child last='true'} {else} {include file=$branche_tpl_path node=$child} {/if} to: {if $smarty.foreach.blockCategTree.last} {include file=$branche_tpl_path node=$child depth=1 last='true'} {else} {include file=$branche_tpl_path node=$child depth=1} {/if} and in modules/blockcategories/category-tree-branch.tpl, change line 2 from: {$node.name|escape:html:'UTF-8'} to: {if $depth > 1}{else} {/if}{$node.name|escape:html:'UTF-8'}{if $depth > 1}{else}{/if} and lines 6-10 from: {if $smarty.foreach.categoryTreeBranch.last} {include file=$tpl_dir./category-tree-branch.tpl node=$child last='true'} {else} {include file=$tpl_dir./category-tree-branch.tpl node=$child last='false'} {/if} to: {if $smarty.foreach.categoryTreeBranch.last} {include file=$tpl_dir./category-tree-branch.tpl node=$child depth=$depth+1 last='true'} {else} {include file=$tpl_dir./category-tree-branch.tpl node=$child depth=$depth+1 last='false'} {/if} This will make the first-level categories paragraphs instead of links. You can add code like the following to your global.css to style the headings: div#categories_block_left ul.tree p { background-color: light-blue } Link to comment Share on other sites More sharing options...
junfu Posted May 19, 2010 Share Posted May 19, 2010 Hi Rocky,this works great but how do I get the top link out of the breadcrumb?thank you Link to comment Share on other sites More sharing options...
rocky Posted May 19, 2010 Share Posted May 19, 2010 Change the following code on lines 586-590 of classes/Tools.php from: if ($category->id == 1) return ''.$path.''; to: if ($category->id == 1) { $path = substr($path, strpos($path, '') + 41 + sizeof(Configuration::get('PS_NAVIGATION_PIPE'))); return ''.$path.''; } and line 619 from: return self::getPath($id_category, Category::hideCategoryPosition($category->name), true).''.$pipe.' '.htmlentities($end, ENT_NOQUOTES, 'UTF-8').''; to: return ($category->id_parent == 1 ? '' : self::getPath($id_category, Category::hideCategoryPosition($category->name), true).''.$pipe.' ').''.htmlentities($end, ENT_NOQUOTES, 'UTF-8').''; Link to comment Share on other sites More sharing options...
junfu Posted May 20, 2010 Share Posted May 20, 2010 Thanks Rocky your the greatest Joyce Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now