@Dan meant this:
<nav role="navigation" itemscope="itemscope" itemtype="http://schema.org/SiteNavigationElement"><?php
wp_nav_menu([
'container' => '',
'items_wrap' => '<ul>%3$s</ul>',
...
]);
?></nav>
Related Posts:
- Hide a menu-item and its submenus and display a ‘Log in’ link if the user is logged out
- The best way to customize “nav-menu-template.php” to add if the ‘link_before’ is “checkbox”
- Run a filter when a walker runs
- How do I add custom bulk actions to multiple custom post types?
- Add data attribute to each li in menu
- Unique icons next to each WordPress menu item
- Redirect to another page using contact form 7? [closed]
- Add item to top of menu using a filter in functions.php
- Get the name of menu item with wp_nav_menu
- How to add different menu items on different menus?
- How to make a image-size selected by default in Media upload – WP v3.5
- start_lvl Ignored in Custom walker_nav_menu
- static variable loop not working in WordPress
- Hide main div if wp_nav_menu is empty
- adding a filter to a shortcode?
- Check if a menu is empty?
- Change the footer text on the login page
- How to remove a metabox from menu editor page?
- add_filter to post-gallery and remove all ‘s?
- Set the transport of the Customizer ‘header_image’ core setting to ‘postMessage’
- Dynamically change feature image in customiser
- How to overwrite youtube embed?
- Rewriting search and pagination base
- Change comments form title on a page by page basis
- Remove class that has been added by parent theme
- How to add active class to custom menu using while loop and wp_list_pages
- Design view breaking on Pages
- Understanding WordPress child theme custom JS loading
- How can I loop into two different DIVS without repeating the DIVs
- Removing unnecessary wordpress files
- How do I know what variables are passed in a filter/action and what their meaning is?
- Is the regular ajax request method safe or I should use admin-ajax.php?
- Can I change a variable in a content part while calling it?
- How to make thumbnail image fit into a div where image dimentions are completely different?
- Have CSS Class Added with `is_page()` WP function
- Set WordPress Default Template
- Get_avatar filter?
- Input type search in Menu
- Create another “Display Site Title and Tagline” checkbox, “Header Text Color” setting and control
- Converting HTML Template to WordPress Theme
- How to remove the cufon script from Dzonia Lite theme [closed]
- How can I remove a function that has been added to wordpress with add_filter?
- what is the best practice to add new field to an api route
- How to add an arrow to menu items has submenus
- Error in custom php function doesn’t exist
- Generating an nonce for Content Security Policy and all scripts – How to make it match/persist for each page load?
- Child page menu in sidebar
- Populate editor with some content of a page with a page template
- Title Case WordPress Menu Items
- Skt full width basic slideshow problem
- How to change menu order item
- How to disable controls in theme customizer?
- Alter required message using comment form api
- Override a function defined in wp-includes/comment-template.php
- Show About and Contact Us page when they’re clicked in the top menu.
- How to call multiple functions from multiple files into a WordPress page template [closed]
- Add login hyperlink to secondary navigation menu
- Content filter won’t work
- What is the best way to define constant options for a theme?
- Warning: in_array() null given in PHP function
- Upload multiple files in randomly generated folder using wp_upload_bits
- Create page template via functions.php?
- How to have different site identity logos on each page on Astra Theme [closed]
- wp_nav_menu not working correctly in my underscores theme
- Removing “Powered by” footer using child theme PHP [closed]
- Get css class of menu item in custom menu structure
- Is there a hack for using is_page() within the function.php file?
- Extract and display user infromation on an automatically created page
- How to correctly load a different version of main menu based on the user language in WordPress? Is it a good solution?
- How can I assign separate stylesheets to different pages?
- Remove submenu item from list
- How to tell if a user has gone in and created a menu
- Remove the Tag from wp_nav_menu
- Menu not styling. New menus functionality giving me a headache
- User filter posts by year
- Getting text from custom field from customizer
- Dynamically switch file in get_template_directory_uri() | Function [closed]
- Providin exception to WordPress wp_nav_menu Custom CSS Classes
- How to change basename url for wp-admin?
- Problem with displaying CSS Stylesheets – Am I adding them correctly in my wordpress child theme?
- require get_template_directory() . ‘path/to-my/file.php’ BREAKS customize > themes functionality
- How to put 2 php codes in functions.php without site crashing
- Menu not updating for logged in users after redirect
- How to bind each “the_content” elements to a custom variables
- Add parent menu item in sub-menu in custom nav_walker
- Custom Bulk Actions handler not firing
- How to generate customized filtered output for the gallery
- Fatal error when using array_diff() function inside of wp_update_nav_menu hook?
- Theme editing “post thumbnail” help
- Pulling a variable into the wp_nav_menu function
- Where can I find the declaration of `$_wp_theme_features`?
- How I can add div to menu?
- A Customizer checkbox control that sets the setting to “” or to “blank” and show() or hide() a color control
- My customizer’s setting doesn’t set to the default and needed to click the control’s “Default” button before it’ll be set
- Save the outputted image into the Media Library, with a different filename and extension
- Search box background on a different page template
- WordPress causing all code to be displayed on line 1. Receiving multiple errors after cleaning cookies and cache
- AJAX: WordPress filters inside $html do not work as intended
- I need a button to appear when not loged in and another when logged in, I need help fixing code PLEASE!
- Custom Navigation Bar JSON Syntax Error in JSON at Position 0