You could write a custom walker to change the output of wp_nav_menu()
. The walker should extend the function start_el()
to add your attributes where you need them. Another option would be a filter on 'walker_nav_menu_start_el'
.
But be aware that tabindex
can make a page less accessible. If don’t have an urgent problem to solve do not use tabindex
.
Related Posts:
- Split up wp_nav_menu with custom walker
- how to create a menu with all sub categories?
- WordPress Menu Custom Walker Class
- How to change order of menu items
- Remove unusable metaboxes in nav menu management screen
- Highlight parent menu item when child is not in menu
- Add Commas Between Menu Items?
- Allow html tags in WordPress Custom Menus Description Field
- Add custom attribute to menu item link using Filter
- Show child pages by menu order using Superfish Dropdown menu?
- Bootstrap drop down menu with wp_nav_menu
- Remove nav menu or menu item
- Adding a within ‘s from wp_nav_menu()
- Building a Sub-menu: Display Parent Category/Page’s Children When Viewing Children
- Getting stripos error when trying to add menu classes
- Output the aria-labelledby parameter for a nav menu child
- Custom Walker for Walker_Nav_Menu
- Make compatible custom menu widget for Twitter Bootstrap
- Different side menu on each page
- Automatically generated menu
- Menu styling for last menu item
- WP Nav menu append to url
- Must a page be published in order to be added to menu?
- Hiding Admin Page While Keeping Menu Expanded
- How to add a tag to wp_nav_menu in a child theme
- Third level navigation class
- How to add a submenu toggle button inside all “li” elements that have a submenu?
- Best way to customise wp_nav_menu [duplicate]
- is_page() not working with archives?
- How to Overwrite/Customize wp-admin/nav-menus.php in WordPress
- Filter for Admin Nav Menus Drop Down
- How do you manage large menu hierarchies in WP?
- Add a class at specific element in custom Menu Walker
- wp_list_pages() but only show children on the branch you are on
- Tidy nav menu classes except for edit-menu-item-classes and active class
- I need help adding a second custom menu item to the WooCommerce account area menu
- Cant add menu items with my theme
- Why aren’t my post showing under my custom menu?
- Dynamically add sub menu items
- Custom Menu’s – Disable Link checkbox
- Alternative to wp_get_nav_menu_items?
- Using my WordPress menu on another platform
- Header and nav menu problem on Thesis site [closed]
- How to style a specific nav menu item?
- remove class “sub-menu” from wordpress drop down menu
- Add a submenu to wp_nav_menu
- Twenty seventeen Menu is not responsive not clickble
- remove menu items if user can’t read
- How to set classname for tag in wordpress menu?
- Automatically going to the first page in a hierarchy?
- Is there a hook for nav menu item links to add custom css programatically?
- rearrange the posts by published date in Menu posts selection
- Setting color of specific menu items depending on page or post tag
- sub menu link is not working
- wp_get_archives doesn’t take effect from css or html
- Orderby menu_order not working; menu is sorted on publish date
- Change Menu Button Text [closed]
- Menu page with three columns
- Appearance > Menus > Left Sidebar > Add Toggle
- How to open a lightbox form from a navigation menu item
- Hide custom menu when when no menu selected
- Efficient wp mobile menu
- Echo Menu located in primary navigation
- Auto delete menu items with zero products (woocommerce)
- Why is my navigation in my onepage not working?
- Admin menu in different languages
- Navigation item – current date in url
- Edited one page in my working menu and now all menu buttons don’t open unless I right-click and open in new tab
- Need help with Walker_Nav_Menu class
- Impossible to remove page from menu
- why are my walker menu is showing like this?
- Bootstrap Theme Migrated to WordPress
- How to remove top menu item and font awesome icon in WordPress menu?
- Menu with sub-items but without link
- Creating navigation out of specific IDs and their children?
- I can´t make the menu unclickable in an easy way
- 2nd level (drop-down) of the navigation menu not working [closed]
- Add active class to wp_nav_menu
- how to configure this type of menu
- Migrate WP Menu between sites
- show a hidden ul if li is active
- How can I make menu items into two seperate buttons with different functions?
- How to style wp_nav_menu?
- How to inject HTML to secondary menu on front end?
- Different colors for navigation bar
- Show Child of Parent Page including all other parents
- Add item ONLY to the primairy navigation
- wp_nav_menu in 3.7 add name class nav navbar-nav
- WordPress Navigation default output
- Specifying Class style for Menu
- Is there a limit to number of pages displayed for selection in custom menu?
- Convert HTML code to WordPress menu
- How to view menu and submenus in URL
- Add monthly archives menu and submenu
- wp nav menu – highlighting current page not working properly [closed]
- Hamburger Navigation Menu
- how to add permalink/slug to wordpress custom link menu item
- Using walker to display all menu branches at once?
- How to add a class directly on a unordered list element that is a primary navigation
- How to change WP menu item type?