📘
Magento 2 Megamenu
  • Overview
  • Installation
    • Setup via FTP or cPanel
  • Config and Usage
    • Install sample data
    • Module Configuration
    • Manage Megamenu
    • Create New Megamenu Profile
    • Configure menu item
    • Show menu on frontend Desktop
    • Show Menu On Frontend Mobile
    • How to use Magento 2 Pagebuilder
    • REST API
    • Graph Ql
  • FAQ
    • How to make desktop and mobile menu on same page?
    • How to use dynamic content tabs for sub menu items?
    • How to add a menu using Widget?
    • How to add products in submenu
    • How to show parent menu and sub menus in the same level
    • How to add label into menu items
    • How to add menu link to category and sub categories?
    • How to change default horizontal menu on header?
    • Problem when import larger categories into menu items?
    • How to show accordion menu on Desktop view?
  • Theme Compatible
    • Porto
    • Codazon Fastest Fashion
    • Ultimo
  • Video Tutorials
    • Video guides
Powered by GitBook
On this page

Was this helpful?

  1. Config and Usage

Show menu on frontend Desktop

Apply when screen width more than 768px. There are 3 template types:

PreviousConfigure menu itemNextShow Menu On Frontend Mobile

Last updated 2 years ago

Was this helpful?

Default menu profile with alias = "menu-top" (normal version) or "top-menu" (pro version) will show on frontend.

In order to change magento 2 default menu, please follow our below tutorials step by step.

1. Create the file app/design/THEME_VENDOR/THEME/Ves_Megamenu/layout/default.xml

2. Add code bellow into the file content and change YOUR_MENU_ALIAS_HERE to a menu alias that you want to show

<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceBlock name="store.menu">
           <block class="Ves\Megamenu\Block\Menu" name="catalog.topnav" template="Ves_Megamenu::topmenu.phtml" ttl="3600">
             <arguments>
                 <argument name="alias" xsi:type="string">YOUR_MENU_ALIAS_HERE</argument>
             </arguments> 
          </block>
       </referenceBlock>
 </body>
</page>

Horizontal Menu

Vertical Menu Left

Vertical Menu Right

Horizon Menu
Vertical Menu Left
Vertical Menu Right