freemall Posted March 28, 2014 Share Posted March 28, 2014 (edited) I want to modify Horizontal Menu as it shows categories up to depth 4, which makes it too big, I want to change the depth to 3 so that it will look nice, my current menu is attached Edited March 28, 2014 by freemall (see edit history) Link to comment Share on other sites More sharing options...
kkmixs Posted March 29, 2014 Share Posted March 29, 2014 Same problem..Any one can help.I donot want to show the sub category at all in top menu Link to comment Share on other sites More sharing options...
Guest Posted March 29, 2014 Share Posted March 29, 2014 Same here, any luck? I just want to display top level, or perhaps level 2 Link to comment Share on other sites More sharing options...
vekia Posted April 5, 2014 Share Posted April 5, 2014 I want to modify Horizontal Menu as it shows categories up to depth 4, which makes it too big, I want to change the depth to 3 so that it will look nice, my current menu is attached you can use this code: #block_top_menu ul li li li ul {display:none!important;} paste this code to your styleseet file (global.css) in addition i see that you use ccc for css files in this case you have to clear cache after change tpl/css files. effect: based on: hide subcategories in block top menu 3 Link to comment Share on other sites More sharing options...
freemall Posted April 5, 2014 Author Share Posted April 5, 2014 should i past it any where Link to comment Share on other sites More sharing options...
vekia Posted April 5, 2014 Share Posted April 5, 2014 you can paste this code at the end of the global.css file Link to comment Share on other sites More sharing options...
freemall Posted April 5, 2014 Author Share Posted April 5, 2014 Thanks a lot it works, could you explain the solution ? thanks again sir Link to comment Share on other sites More sharing options...
vekia Posted April 5, 2014 Share Posted April 5, 2014 #block_top_menu ul li li li ul {display:none!important;} this code just hide all <ul> (listings) of categories li - first element li li - second element li li li - third element so this code hide all of category listings above the 3 level 1 Link to comment Share on other sites More sharing options...
falkor Posted April 10, 2014 Share Posted April 10, 2014 (edited) #block_top_menu ul li li li ul {display:none!important;} this code just hide all <ul> (listings) of categories li - first element li li - second element li li li - third element so this code hide all of category listings above the 3 level Firstly I want to add 1 thing: #block_top_menu ul li selector will work on #block_top_menu ul li li too. If you want to select 1 level below you should use #block_top_menu ul > li Secondly: In my opinion this solution is not good enough because you shouldn't hide any navigation elements (its bad for SEO) EDIT: So I still waiting for 'number of levels' input in module. Edited April 10, 2014 by falkor (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted April 10, 2014 Share Posted April 10, 2014 Secondly: In my opinion this solution is not good enough because you shouldn't hide any navigation elements (its bad for SEO) as far as i know browsers can't distinct if an <ul> or any other element is hidden by jquery/css styles (display:none) This "display:none" works the same as it works in native, see - whole default top menu sub items are also hidden, only if you hover mouse over it (menu items) it is visible (dispaly:block) - it's not true that it's bad for seo. Link to comment Share on other sites More sharing options...
falkor Posted April 10, 2014 Share Posted April 10, 2014 Ok, so you gave me a reason to blame our SEO guy (jk he's nice guy)He always want us to clear display:none elemets etc.Good to know. Link to comment Share on other sites More sharing options...
Geoff1066 Posted May 6, 2014 Share Posted May 6, 2014 This helped me, good thread 1 Link to comment Share on other sites More sharing options...
jesnasali Posted June 1, 2014 Share Posted June 1, 2014 Hi I found a solution for your issue. Try this open blockmenutop.php go to function generateCategoriesMenu find this block if (isset($category['children']) && !empty($category['children'])) { } now add this block inside the following condition if($category['level_depth'] <=2){ if (isset($category['children']) && !empty($category['children'])) { } } save file, clear cache and reload your store home page Link to comment Share on other sites More sharing options...
vekia Posted June 1, 2014 Share Posted June 1, 2014 in my opiniton it's not worth to deal with .tpl file these categories will not be included to page, so these categories will not be visible, it's like a suicide related to seo cases. with css these links will be still there. 1 Link to comment Share on other sites More sharing options...
Recommended Posts