Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #767799

    HI I have left sidebar second level navigation menus on all my pages (and some third level).

    I much prefer this for desktop.

    But on mobile I want to have my second and third level navigation within the hamburger navigation.

    Is this possible?

    Many thanks

    Jenny

    #768252

    Hey Jenny,

    Please refer to this post – http://kriesi.at/documentation/enfold/hide-menu-itemselements-on-mobile/

    Best regards,
    Yigit

    #785422

    Thank for your help Yigit but that link seems to show how to hide menu items on mobile whereas I want to add them. Can you advise please?

    Many thanks

    Jenny

    #785676

    Hi Jenny,

    Please refer to this post instead – https://kriesi.at/support/topic/change-mobile-menu-2/#post-784018 :)

    Best regards,
    Yigit

    #786042

    Thanks Yigit if I use the code you suggested on that post as below to create 2 different menus, what should I name the 2 menus or does this not matter?

    Thanks

    Jenny

    function av_different_mobile_menu( $args = ” ) {

    if(wp_is_mobile()) {
    $args[‘menu’] = ‘main-menu-mobile’;
    } else {
    $args[‘menu’] = ‘main-menu’;
    }
    return $args;
    }
    add_filter( ‘wp_nav_menu_args’, ‘av_different_mobile_menu’ );

    #786053

    Hi!

    You should name desktop menu “main-menu” and mobile menu “main-menu-mobile”. You can of course name them differently but you would need to update the names in the code as well :)

    Best regards,
    Yigit

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.