Mega Menu

Create an expanding menu based on a visitor's selections.

Code Level

Intermediate

Published

 

Example Description

In this example, we created a menu that branches into submenus. The choices in each submenu are customized based on the visitor’s previous selections. In the final submenu, each button links to a page with product listings.

Note: The code is in the Site tab instead of the Page tab of the code panel so you can add the menu to any page in your site.​

Example Code

How We Built It

We used repeaters to create our menus and populated menu button labels and links with data from our collections.

 

We added code to filter our collections based on the visitor selections. Then we used the filtered data to populate the submenu repeaters.

​​

Next Steps

  1. Open this example in the Editor to work with the template.

  2. Publish the site.

  3. Learn how to work with examples in Corvid.

APIs We Used

Related Articles

Related Examples

Add to Cart Gallery

Let customers to add products to their cart

INTERMEDIATE

Hide and Show Elements

Hide and show elements in response to user interactions

BEGGINER

Hide and Show Elements

Hide and show elements in response to user interactions

BEGGINER