Jump to content
Sign in to follow this  
augemundial

Switch SiteBranding to BrandNav when user is logged in

Recommended Posts

augemundial

In my header I want to show the regular sitebranding section, but when a user is logged in (because I'm using Buddypress) I only want to show BrandNav in order to save space. Anyone can help me to do this? Thank you :)!

Share this post


Link to post
Share on other sites
kastelic

Try:

	.logged-in #branding {display:none}
	

Share this post


Link to post
Share on other sites
augemundial
Thanks kastelic, that's a clever tip. However "BrandNav section" also adds a navigation bar, which will still appear even if I hide #branding. I want to use "Site branding" in my header when the user is not a member, and "BrandNav" otherwise. Suggestions?

Share this post


Link to post
Share on other sites
kastelic
You could enable both sections in the header. Then hide one with the .logged-in class, and hide the other by default with display:none and set it to display:block with the logged-in class.

Share this post


Link to post
Share on other sites
augemundial
Thank you, that does the trick. In posting my CSS snippet for the non-CSS savvy like me. .logged-in #branding, .logged-in #primary-nav {display:none} .logged-in #brandnav {display:block} #brandnav {display:none;}

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this  

×