Home Forums WoodMart support forum Open Main Menu Item from Outside Link

Open Main Menu Item from Outside Link

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #157371

    webaits
    Participant

    Hi,

    I’m trying to open a main-menu item from a link residing in the topbar. Here are the steps:

    1. Go to the website https://www.craftesy.com
    2. There is a link “OPEN WOMEN CLOTHING MENU” in the topbar
    3. Upon clicking to it, the “Women Clothing” menu in the main-menu should expand.
    4. However, due to some code in the theme’s functions.js, this is not happening. Only the alert message from the code below appears.

    Below is my JS code

    $('.btn-owcm').click(function(e){
    		alert('Trying to open Women Clothing from the main menu');
    		$('#menu-item-25').click();
    		//$('#menu-item-25 > a').click();
    		//$('#menu-desktop #menu-item-25 > a').get(0).click();
    		e.preventDefault();
    	});

    How do I attend the desired behavior?

    Thanks

    #157404

    Hello,

    The main menu cannot be opened from the secondary menu in the header builder. Please read and follow the instructions: https://xtemos.com/docs/woodmart/adding-menu-site/

    Best Regards

Viewing 2 posts - 1 through 2 (of 2 total)