# How to set up Mega menu horizontal

![](https://980438068-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MV0r5tR9bPLGnwB_pyk%2Fuploads%2FJFFvnOXMRC6m2t69aY5V%2FGoogle%20Chrome_2022-03-15%2018-58-41%402x.jpg?alt=media\&token=c6a0474e-442c-4d2b-921e-b70f641044d7)

### Here is the instruction you can follow if you desire to set up a mega menu horizontal for your site:

<mark style="color:blue;">**Step 1**</mark> - Simply, navigate to **Appearance** **→** **Menu**

<mark style="color:blue;">**Step 2**</mark> - Choose **Main Menu** and click Select button

<mark style="color:blue;">**Step 3**</mark> - Go to Shop (Our tutorial video shows an example with the menu item **"SHOP"**), You can do it similarly with other menus. Imagine that we have Shop and inside of it, we need to have four sub-menus. \
Click on **Mega Menu** and **Full-Width** option if you want to display the full-screen mega menu

![](https://980438068-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MV0r5tR9bPLGnwB_pyk%2Fuploads%2FgfAUWuQSlB3NfXnrRSHv%2Fimage.png?alt=media\&token=ff97a7aa-6b88-4445-9537-5fac88e9fa73)

<mark style="color:blue;">**Step 4**</mark> - Drag and drop to have 4 submenus

![](https://980438068-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MV0r5tR9bPLGnwB_pyk%2Fuploads%2FuXDYzISZaNFZFciDyllq%2Fimage.png?alt=media\&token=1d3e5085-b9dc-4252-b58f-58215898ae2f)

#### **In addition, our theme is designed by default with 3 levels of sub-menu, if you want to display sub-menu with 4 levels , please insert the following code in / wp-content / themes / elessi-theme-child / functions .php:**

{% tabs %}
{% tab title="PHP" %}
{% code title="function" %}

```php
add_filter ('nasa_max_depth_main_menu','custom_max_depth_menu');

function custom_max_depth_menu ($depth) {

return 4; // Return max depth menu - Default is 3
}

/* ====================== */
```

{% endcode %}
{% endtab %}
{% endtabs %}

### <mark style="color:red;">RESULT</mark>

![](https://980438068-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-MV0r5tR9bPLGnwB_pyk%2Fuploads%2FoyOx7BytJGNp4kaYxL2w%2FGoogle%20Chrome_2022-03-11%2017-50-23%402x.jpg?alt=media\&token=529a0d5a-2c6f-492e-83d3-adcadb686e58)

![Please change the number here if you want to up any sub-menu levels](https://980438068-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MV0r5tR9bPLGnwB_pyk%2F-MlEV5pI2GKETBZUsBjN%2F-MlFgZaXq2szzOvmAogp%2FOpera_2021-10-05%2020-43-44%402x.jpg?alt=media\&token=7cbd08e8-9f51-4292-a833-27edaaee4edf)
