WordPress.org

Ready to get started?Download WordPress

Codex

Attention Interested in functions, hooks, classes, or methods? Check out the new WordPress Code Reference!

Function Reference/unregister nav menu

Contents

Description

Unregisters a custom navigation menu for a theme location.

Usage

 <?php unregister_nav_menu$location ); ?> 

Parameters

$location
(string) (required) Menu location identifier slug.
Default: None

Return Values

bool True on success, false on failure.

Example

 <?php unregister_nav_menu'primary' ); ?> 

Changelog

Source File

Related

Navigation Menu: register_nav_menus(), register_nav_menu(), unregister_nav_menu(), has_nav_menu(), wp_nav_menu(), wp_get_nav_menu_items()

See also index of Function Reference and index of Template Tags.