I’m trying to remove the link to the home page in my wp_nav_menu but it’s not working. The him page is a static page I set in the preferences. I found this but it doesn’t seem to work so I’m obviously doing something wrong. Is there a better way to do this?
This is my functions.php:
register_nav_menus(array('primary' => 'Primary Navigation'));
/* Remove Home Page Link */
function mytheme_nav_menu_args( $args ) {
$args['show_home'] = false;
return $args;
}
add_filter( 'wp_nav_menu_args', 'mytheme_nav_menu_args' );