I am building a custom site where i'll be customizing the sample theme. I originally moved the code to the
genesis_before_header action hook, but I realized that I actually need it within the
<header> to style it appropriately. I tried this code and it didn't work:
remove_action( 'genesis_after_header', 'genesis_do_nav' ); add_action( 'genesis_header', 'genesis_do_nav', 1);
Any ideas on how to get this to work?
Give this a try. It moves in into the header. It does create some styling differences because of the context, though!
add_action( 'genesis_header', 'genesis_do_nav', 12);
Thank you for the quick response! That executes
genesis_do_nav() in the
<header> element, but does it at the bottom. I need this to execute before anything else in the header. Meaning before the site title/header image and header right, but still within the n
Does that make sense?
Yes, I do get it. Now that Genesis 2 is all HTML5, some experimentation is needed with priority to get things exactly where you want them. Because that's sort of a big secret, I wrote an article about that, but I didn't mention the header, I mostly concentrated on the content area. So I'd suggest playing with the number, and see what you get.
My own tendency is to get things in the general area, and because of my CSS knowledge, I can finesse whatever I need that way.
Looks like a priority of 5 did the trick!
You must be logged in to reply to this topic.
Subscribe to get early access to new themes, discounts and brief updates about what's new with StudioPress!