New Landing How can we help? Themeforest Theme Support Dante Mobile menu toggle submenu

Viewing 7 posts - 16 through 22 (of 22 total)
  • Posted in: Dante
  • #300445
    hentsch
    Member
    Post count: 28

    Hi Elias,
    Isn’t it exactly what happends with my second solution ?
    Have a look here for an example (with a mobile device of course 😉 : https://mouskif.ch/voyages-camps/yoga-escalade/
    Vincent

    #300516
    David Martin – Support
    Moderator
    Post count: 20834

    Thanks @Vincent for sharing the snippets.

    #300542
    3lias
    Member
    Post count: 128

    Vincent, almost. Your solution is made of a main-menu (with no content/link to open a site) and submenus with content/links to a specific page. The menu I have will open a site when clicking at the main-menu link. I hope this makes sense to you. Maybe the snippet needs just a small adjustment so it will work also in my case.

    #300627
    hentsch
    Member
    Post count: 28

    ok, perhaps just like this :
    Just put it in custom JS of theme options

    jQuery(document).ready( function ($) {
    	$( "#mobile-menu ul.sub-menu" ).not( ".current-menu-ancestor > ul.sub-menu" ).hide();
    });

    with this in custom css to be more visible :

    #mobile-menu .menu li.current-menu-ancestor > a, #mobile-menu .menu ul li.current-menu-ancestor > a, #mobile-menu .menu ul li.current-menu-item > a {
        background-color: #313131!important;
    }
    #300693
    Rui Guerreiro – SUPPORT
    Keymaster
    Post count: 25779

    thanks @hentsch

    -Rui

    #300793
    3lias
    Member
    Post count: 128

    @hentsch Thanks for your code which works for sub-menus very good but if there is a initial click at a main-menu item (which has sub-menus) the submenu is not displayed unless one of the sub-menu sites have been opened. See image below.

    Any idea what to add to the code?

    Attachments:
    You must be logged in to view attached files.
    #301178
    David Martin – Support
    Moderator
    Post count: 20834

    @3lias – your question might be better answered on Stackoverflow or by hiring a developer to assist you further.

    Thanks.

Viewing 7 posts - 16 through 22 (of 22 total)

You must be logged in and have valid license to reply to this topic.

License required for the following item
Login and Registration Log in · Register