Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I've created a sticky menu but its hidden behind the WordPress Toolbar when logged in. How do i move it below the toolbar when enabled and logged in?

I was looking for a conditional tag but couldn't find one for this. I guess there's a WordPress hook or filter that i could use.

share|improve this question
add comment

3 Answers

The best way to go about doing this is to simply move the admin bar to the bottom with this plugin. Its so simply, clean and less confusing. I use it for all my sticky menu sites.

LINK: http://wordpress.org/plugins/stick-admin-bar-to-bottom/

I know this doesnt "exactly" answer your questions buts its a great alternative.

share|improve this answer
add comment
body.admin-bar div.sticky.fixed { margin-top: 28px; }
share|improve this answer
    
Please explain your code rather than just post the code itself. –  s_ha_dum Oct 11 '13 at 21:18
add comment

I assume you mean on the admin bar on the front end, that show up for logged in users.

The body_class function inserts a class called admin-bar when that is present. The admin bar is 28px high. You should be able to use that body class to conditionally relocate your sticky menu.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.