Yesterday, I was having an issue with horizontal top menu as I wanted to make them invisible on frontend. I made it invisible by using css as:

body.cms-my-homepage div.main-menu.menu-style-2{display:none}

And it worked for me but this code also disabled the mobile menu. Is there any other way, means by which I can enable the mobile menu or specify a new mobile menu?

  • 1
    For hiding menu only for desktop, you can use media query for above CSS
    – Pawan
    Feb 24, 2018 at 6:33
  • yeah how can i forget that! thanks for reminding me @pawan
    – Laiba
    Feb 24, 2018 at 6:35
  • Welcome @Laiba.
    – Pawan
    Feb 24, 2018 at 6:38

1 Answer 1


You can use following code in your CSS for displaying menu in your mobile device

@media only screen and (max-width: 767px) {
    body.cms-my-homepage div.main-menu.menu-style-2{display:block}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.