The following should setup your menu with the correct classes and IDs applied to your container and ul. The codex entry for wp_nav_menu lists all the possible arguments.
wp_nav_menu( array(
'theme_location' => 'primary',
'container_class' => 'menu-menu-container',
'menu_id' => 'menu-menu',
'menu_class' => 'btn-group'
) );
You can then add the required classes to the menu items by using the nav_menu_css_class filter.
function my_special_nav_class( $classes, $item ) {
$classes[] = 'btn btn-default';
return $classes;
}
add_filter( 'nav_menu_css_class', 'my_special_nav_class', 10, 2 );
Related Posts:
- adding some custom html code to the wp_nav_menu function
- Multi Level Bootstrap Navigation Menu in WordPress
- How do I add the data-toggle=”modal” data-target=”#myModal” attribures to a WP Nav bar?
- Bootstrap drop down menu with wp_nav_menu
- wordpress nav menu using twitter bootstrap
- HTML Bootstrap navigation menu to WordPress menu using wp_nav_menu
- Output the aria-labelledby parameter for a nav menu child
- Add Bootstrap dropdown class to a nav menu
- Nav walker, bootstrap: Display 3rd level items under 2nd level
- Make compatible custom menu widget for Twitter Bootstrap
- Loop through Navbar, Output Icons
- How can I remove data-target=”#” from bootstrap dropdown menu?
- Make menu bootstrap compatible
- Main Menu and Sub Menu Items for Footer
- How to add class to and childs of sidebar widget – WordPress
- How to have two menus using Bootstrap nav walker?
- Side Menu Icon Expandable
- WordPress Walker – Group two items?
- Sticky Header in WordPress using BootstrapWP theme [closed]
- WordPress + Bootstrap [closed]
- wp_nav_menu not displaying the right way
- wp_get_archives doesn’t take effect from css or html
- Make two bootstrap menus collapse into one dropdown
- WP nav menu + Bootstrap, add role=”menu” to UL
- Responsive menu on genesis theme [closed]
- Bootstrap menu – make menu entries with submenu not clickable
- Bootstrap Menu bar shows up a toggle in Desktop Mode
- WordPress + Bootstrap: Replace primary navigation menu on mobile?
- Stuck while adding bootstrap navwalker class
- How to use Bootstrap Navbar in wordpress Nav Menu
- Navbar is hidden behind carousel when using wp-boostrap-navwalker
- How to create a mobile menu full screen overlay using Understraps Bootstrap 4 theme
- Bootstrap Nav Walker Sub Menu Image
- Change menu for mobile
- How to change navwalker’s dropdown mark-up?
- Bootstrap navbar responsiveness on WordPress theme menu not working
- My WordPress menu based on Twitter bootstrap creates menu-item and not page-item
- Broken drop down menu using Bootstrap and navwalker class
- nav tag wrapping around dropdown
- Convert a custom bootsrap based menu to wordpress nav walker
- WordPress nav Walker – Bootstrap 5.2.3 – submenu not opening
- Nav walker bootstrap: Display 3rd level and 4th level in dropdown menu
- Unregister Nav Menu from Child-Theme
- Deleted pages are NOT removed from custom menus?
- Keeping parent menu items active in child pages
- Add Page ID class to nav menu items
- Way to bulk delete menu items in new 3.x Appearance > Menus system?
- Pass a parameter to a menu walker
- WordPress nav_menu_link_attributes Not Working
- Customize the menu by adding items
- wp_nav_menu log in/out link?
- Accesibility problems with dropdown menus in twentyten theme or others
- Theme menu in Admin Panel
- How to target children of child pages
- How to insert custom code into wp_nav_menu structure?
- getting parent page id when using custom menu.
- Change name & menu_name for Profile in the default menu, w/o altering core files?
- wp-menu ‘automatically add custom taxonomy terms’ like it does for pages? [closed]
- How I can overlap my menu in my header picture
- current-menu-item class in CSS
- Put class on instead li
- Tiles as a navigation
- How to make the Primary Menu stay the same in the PC and mobile versions of the Twenty Sixteen theme
- Page content loading issue using Walker_Nav_Menu
- Using my WordPress menu on another platform
- Header and nav menu problem on Thesis site [closed]
- How to remove menu labels in word press?
- Adding a unique ID to each sub-menu
- How to add css to single navigation text? [closed]
- My navigation menu isn’t working. What happened? Please help!
- How to get a multidimensional array of my menu?
- How to add search to menu?
- How to get submenu of admin menu?
- Show wp_nav_menu() based on URL with no fallback
- Editing the nav menu?
- How to display conditional menus with Twenty-twenty two theme (and other new block themes)?
- Keep source page URL parameters on custom link menu item
- I’m trying to remove a duplicate menu, which only appears on the homepage?
- Embedding an external webpage within a page? Is it possible, is it a good idea?
- How to remove empty line space in navigation menu?
- Is it possible to get_the_post_thumbnail (Featured Image) inside a sprintf function?
- WP Menu editor is hiding options for menu items
- Assign a different menu depending on custom taxonomy
- Appearance -> Menu editor completely unresponsive
- Custom menu is rendered in all menus
- javascript i wrote not working, can’t figure out why [closed]
- Making my main menu a hamburger menu on all platforms
- how to create pages and link them to a menu
- menu mobile show up even i in desktop mode in Newspaper Theme
- WordPress fountainpress header is covering top bar
- Outputting Page Title As Tooltip
- How to add class and span to
- Appearance > Menus
- extra tag is added in wp_nav_menu
- Additional class for.sub-menu UL?
- How do I show a different secondary navigation menu for each section of my website?
- How can I alter the visible menu according to which level I am on [closed]
- How to center top Menu bar [closed]
- Changing when mobile menu is displayed
- Navigation menu displays permalinks