September 11, 2013 at 12:38 am #7315
Just wondering which genesis hook I should adjust too when trying to re-position the Primary Navigation below the Slider?
// Reposition the Primary Navigation
remove_action( ‘genesis_after_header’, ‘genesis_do_nav’ ) ;
add_action( ‘genesis_after_header’, ‘genesis_do_nav’ );
Based on having a look at the visual hook guide there are no real hooks for moving this navigation below the slider, should this just be done using CSS?
Thanks!September 11, 2013 at 1:05 pm #7329
Use after_header like you’re doing, but add a priority to the Slider so it shows up above the nav. You’ll have to play around with the numbers until it gets in the right spot you want.
September 17, 2013 at 12:05 am #7458
Where do I set the priority? As in adjust the zindex in css? Or somewhere in the JS?
Thanks!September 17, 2013 at 12:42 am #7459
background-image: -webkit-gradient(linear,left top,left bottom,from(#fff),to(#f2f2f2));
margin: 0 auto 40px;
I did that, it’s working fine in Firefox but I assume it’s going to break on portability or some browsers but perhaps this will help others set me right.. I assume z-index is being totally ignored and its just the positioning values I have used that is moving things around though?September 19, 2013 at 11:26 am #7486
Priority should be added to the action not the css. Like this –
add_action( ‘genesis_after_header’, ‘genesis_do_nav’, 12 );
Start from 0 and keep raising the number until it gets in the position you want.
September 25, 2013 at 4:09 am #7606
Thanks, gave that a go and it doesn’t seem to make much difference. Using 12 put’s it right below all the home page widgets.
Do I need to set the priority on other elements that are being displayed in that area? I had a quick look in functions.php and couldn’t really see where I would add the priority for the slider itself.
The main goal for moving the primary navigation below the slider is so the the drop downs menu items are not hidden. Not using a menu in the “Header Right” widget on this occasion.September 25, 2013 at 10:24 pm #7633
I actually meant to start from 0 and work your way up to around 12 or so until you see the nav show up after the slider….or you could just add a priority to the slider and move it up instead to make things easier.
By the way, the slider code is inside the home.php file, if you want to try adding a priority to it instead of the other way. Either way works, I’ve done it before in the past.
- You must be logged in to reply to this topic.