• 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

Sample Theme 2.8 Move Menu Above Header

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 › Sample Theme 2.8 Move Menu Above Header

This topic is: resolved
  • This topic has 2 replies, 2 voices, and was last updated 6 years, 2 months ago by sean nelson.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • February 24, 2019 at 10:09 pm #489706
    sean nelson
    Member

    Looking to move header menu above the header. I've updated the code in the functions file:

    // Repositions primary navigation menu.
    remove_action( 'genesis_after_header', 'genesis_do_nav' );
    add_action( 'genesis_before_header', 'genesis_do_nav', 12 );

    The css has got me a little perplexed. I've played with it so far but feels like I'm hacking it rather than doing things correctly.

    Has anyone figured out the CSS updates to move the header menu to above_header in Genesis Sample Theme 2.8?

    Thanks.

    February 24, 2019 at 10:45 pm #489707
    Victor Font
    Moderator

    I'm assuming you can't see the menu in the before header area? The site header has a fixed position. The menu is behind the header. First, you have to move the header down by adding some margin-top:

    .site-header {
        position: fixed;
        width: 100%;
        z-index: 9999;
        margin-top: 69px;
    }

    Next, you have to make the menu position fixed also. With position fixed, the float: right won't work any longer. You have to adjust the width to 100% and use text-align to move the menu back to the right. You also have to add color to the background or else you will see everything on the page scroll through the menu.

    .nav-primary {
        clear: none;
        width: 100%;
        position: fixed;
        background-color: #fff;
        text-align: right;
    }

    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

    February 24, 2019 at 11:04 pm #489708
    sean nelson
    Member

    Thanks Victor. I had added the background color to see what space the menu was occupying. And applied margin-top:30px to site-header. Then text-align: center. Just felt like I was hacking it to make it work, so your suggestions helped me see that I was on the right path.

    Only thing else I had to add... because I am adding content in the header right widget - removed the function to remove it - was some margin to the top (.header-widget-area) as it was under the menu bar at top, and then float it right because it was sitting next to the logo.

    Prefer the menu in the header but using a mega menu that needs to go full width, so it was not an option in this case.

    Then will remove the header right widget and menu at mobile and replace with wp responsive menu.

    Thanks for the assistance.

  • Author
    Posts
Viewing 3 posts - 1 through 3 (of 3 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

© 2025 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