WordPress.org

Forums

Responsive Select Menu
target only one menu (8 posts)

  1. somtam
    Member
    Posted 2 years ago #

    Hi, and thanks for your plugin!

    I would like to know if it is possible to target only one menu, and not every menu in the page. I call my different menu with:

    wp_nav_menu(array('menu'=>'Main'));
    wp_nav_menu(array('menu'=>'Footer_01'));
    etc...

    I looked inside the code of your plugin, but I can't find where I can put an IF to check if is the Main :(

    thanks a lot!

    http://wordpress.org/extend/plugins/responsive-select-menu/

  2. sevenspark
    Member
    Plugin Author

    Posted 2 years ago #

    Hi somtam,

    At this point it will always target all menus (it's very simple). But I'll try to add the ability to target specific theme_locations in the future. :)

    Best,

    Chris

  3. somtam
    Member
    Posted 2 years ago #

    ok, I'm going to try to custom for the website i'm making.
    Thanks for answer.

  4. ColinD
    Member
    Posted 2 years ago #

    My hacky solution was to set the plugin to a max-width of 100px so it would never switch from menu to select. Then I added display:none to my menu at my real breakpoint and display block to the select.

  5. somtam
    Member
    Posted 2 years ago #

    that's a good and simple idea.
    thanks!

  6. sevenspark
    Member
    Plugin Author

    Posted 2 years ago #

    1.2 now supports selective application of the menu :)

  7. somtam
    Member
    Posted 2 years ago #

    Hello and thanks for reply and make your plugin even better!
    But I have a problem... I do not understand how to select the menu on which I want to apply your responsive menu.
    In the options of your plugin I already set on OFF the Active all theme locations.
    In my Appereance > Menu I have several menu I use in my template. I call them with the function <?php wp_nav_menu(array('menu'=>'main')); ?>.

    thanks!

  8. sevenspark
    Member
    Plugin Author

    Posted 2 years ago #

    You need to use the 'theme_location' parameter rather than the 'menu' parameter :)

    Please see http://codex.wordpress.org/Function_Reference/wp_nav_menu and http://codex.wordpress.org/Function_Reference/register_nav_menu

    Best,

    Chris

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Responsive Select Menu
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

Tags

No tags yet.