• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Remove Secondary Navigation Menu

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › Remove Secondary Navigation Menu

This topic is: not resolved

Tagged: Metro Pro, Secondary Navigation menu

  • This topic has 4 replies, 4 voices, and was last updated 11 years, 1 month ago by Graham.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • February 18, 2015 at 12:39 pm #141224
    Tony-BV
    Participant

    Hi, I just recently changed themes and I am having a little difficulty finding out how to remove the Secondary Navigation Menu on a particular page on the Metro Pro theme. I had it working fine on the other theme, but the code doesn't seem to work with this Metro Pro. Thank you in advance for any help you can provide. Thanks Tony

    http://www.preloadedwebsites.com
    February 18, 2015 at 1:15 pm #141234
    Genesis Developer
    Member

    You will write the code in functions.php file. Code will be like this:

    add_action('genesis_meta', 'gd_remove_menu');
    function gd_remove_menu(){  
        If ( is_page('10') )  // replace value 10 by your page id
            remove_action('genesis_after_header', 'genesis_do_subnav');
     }

    See the WordPress Codex for is_page() function. You will get better idea for it.


    Download Genesis Featured Posts Combo Widget | Simple Grid Layouts Plugin for Posts, CPTs and terms
    You can request new tips/help.

    February 18, 2015 at 2:26 pm #141239
    beachcomberencinitas
    Member

    http://www.beachcomberhottubs.com/locations/encinitas-hot-tubs/local-store

    May 20, 2015 at 4:54 pm #152984
    Tony-BV
    Participant

    Hi, I'm sorry it's been a while, but I tried to add the code you suggested but it still does not hide the menu. Any other suggestions? Thanks in advance, Tony

    May 20, 2015 at 8:31 pm #153024
    Graham
    Member

    In the Metro Pro theme, the secondary menu ( subnav ) is actually hooked on to the 'genesis_before' hook and not 'genesis_after_header' -- so that's the menu right at the top of the page.

    So, tweaking the above code to conditionally remove the secondary menu in the Metro Pro theme - try this.

    add_action( 'template_redirect', 'child_maybe_remove_subnav' );
    function child_maybe_remove_subnav(){  
        If ( is_page('10') )  // replace value 10 by your page id
            remove_action( 'genesis_before', 'genesis_do_subnav' );
     }

    My JustGiving page: https://www.justgiving.com/helping-graham-give

  • Author
    Posts
Viewing 5 posts - 1 through 5 (of 5 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2026 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble