You can filter 'wp_nav_menu_args', set an invalid theme_location and the magic function __return_false as fallback:
add_filter( 'wp_nav_menu_args', 'override_parent_args' );
function override_parent_args( $args )
{
if ( 'header-menu' === $args['theme_location'] )
{
$args['fallback_cb'] = '__return_false';
$args['theme_location'] = 'ticky_tacky';
}
return $args;
}
Related Posts:
- get_template_directory_uri pointing to parent theme not child theme
- How to customize the_archive_title()?
- Different methods of adding menu support to custom theme
- Adding a section in line at the end of the main navigation menu in php
- How to remove admin footer text from inside child theme?
- How to store a number (coming from cookie) into query vars for later usage in other filters?
- How to overwrite template.php file
- Multiple navigation menu in same location
- remove_action not working, even after changing priority [duplicate]
- Solution dealing with Child Theme / Parent theme functions
- Do we need to change our child function.php to require/include child dir files when we add an over-riding file.php into the child theme
- How to use parent theme functions in child theme functions.php file?
- Removing parent theme CSS without editing parent theme
- How to override this theme function in child theme
- wp_nav_menu work in functions.php but not in the theme
- How to register a menu based on a ACF condition
- get_template_directory() – references parent theme directory
- How to hightlight all ancestor menu items of a child page NOT displayed in menu
- Child theme functions.php
- current_page_item is missing inside wp_nav_menu
- search form leads to 404
- Unable to add extra elements to the main navi (wp_nav_menu_items)
- Change custom featured image size in twentythirteen child theme
- How Can I add a menu to the theme from withen the function.php file
- define css class in functions.php
- Overwriting TwentyTwelve template file with child theme template, but lower in the hierarchy
- Custom Menu in Admin doesn’t change menu in browser
- Looking for Functions File that doesn’t Exist
- How would I make a function to dynamically determine if user is logged to change navigation menu text?
- Any adverse effects of adding apply_filters to a function?
- Conditional custom menu?
- wp_nav_menu displaying all pages
- Include widget file in functions.php of child theme
- Warning at top of website & top menu gone
- Get webpack to work on child theme
- how can I add filter in specfic field in my website?
- How to remove font awesome from loading in wp theme
- How to display an image before title text in menu items
- Add custom css file after plugin css with WordPress Child Theme functions.php
- Bizarre Child Menu Issue on WP Site
- Header menu aligned right on all pages except for single-post page [closed]
- Adding a schema code to one specific page using functions.php file
- Add Javascript code to functions.php childtheme
- How Do I Unhook This Parent Theme Function?
- Widget is displayed in two places
- How to automatically add counted number to navigation menu items?
- How to add javascript code into Divi child theme?
- Child theme, how to cut the functions.php file into several classes?
- Replace theme function
- Combine multiple menus using the filter wp_nav_menu_items
- Setting Up Child Theme To Take Priority
- Menu and category highlighting for a single post
- How do I create a child theme from PowerMag theme
- Change default color scheme in twentyfifteen child theme?
- WordPress Toggle Menu has stopped working
- Create New User Custom Field not Saving
- How would I correctly implement a new if statement in a child functions file?
- Will dequeueing in child theme functions.php file prevent Google Fonts from loading?
- Child Theme not loading multiple stylesheets
- How to add widget in main menu
- Including admin-options.php file in Child Themes
- Modified functions.php in Magazine Pro theme of Genesis. 500 error
- Help with is_page() and calling css for specific pages in a Child Theme
- uninstall a theme programmaticlly
- Language Switch Function
- How do I integrate my Child Theme into a Custom Template?
- Getting back a blank WordPress site following functions code edit
- Insert menu into theme location depending on user logged in/out status
- Adding a meta box fields to child theme options page
- Child Theme functions.php has no effect
- Update add_image_size
- Adding custom field in menu options [duplicate]
- Load a Child Theme’s style.css just before the closing tag
- Modify sub_menu function to show pages below a specifically set page
- wp_nav_walker that interacts with widgets to setup mega menu
- Is it possible to change parameters of Parent theme function in the Child theme?
- Preventing PHP Execution in Parent Theme
- Adding a filter with custom function to the menu / navigation
- Blank child theme – functions.php problem
- Why does my visual post editor break when I try to add a TinyMCE button?
- Functions.php in child theme that loads CSS file breaks website
- unregister_sidebar in child theme not working
- Unregistering custom tinymce plugin?
- Override parent theme function that is not hooked or in the functions.php file
- How to add a class name to the ancestor of a post?
- Function Reference for custom link in Admin Menu Management Page
- How do I get my nav menu to show sub pages?
- Problem with Child-Theme using of foundation-framework [closed]
- Notice: Use of undefined constant REQUEST_URI – assumed ‘REQUEST_URI’ in ….functions.php on line 73
- Child Theme not working – CSS gone
- Why functions metaboxes is causing White Screen in Admin [closed]
- How do I make my child theme’s CSS update when I save it?
- Why don’t ‘wp_nav_menu’ CSS classes work until a menu is created?
- How to fix enqueue_styles error for a twenty-seventeen childtheme
- Call wordpress function through functions.php when pressing menu
- How to add more than one menu for logged in members?
- post_row_actions filter from parent theme not executing in child theme
- Proper way to load styles using a child theme
- Add URL parameter to nav links based on domain
- Child theme’s functions.php not being read (child theme’s autoload.php not being run)