Archived topic
Trying to center the logo (w/ no nav) using Elements
3 replies · Started by Andrew on March 31, 2020
Hi Tom and Leo,
Thank you for all your awesome work.
I had one small issue that I haven't been able to a solution in past tickets, so I apologize if this issue has been dealt with before.
Most of the webpages that I'm working on has the logo to the left and the nav floating to the right; however, I have one page that I'm using as a landing page, so I want to center the logo and hide the nav.
I figure the best way to do this is to create a Header Element (to display for the one page) with:
- Horizontal Alignment: Center
- Navigation Location: No Navigation
- Site Logo: added logo
(I also want to set the header to merge with Content with a Header Background, and I have managed to get that part.)
For some reason, the nav is behaving and not showing; however, the site logo won't center. It's staying to the left.
I also made sure to exclude the non-nav page from the other Element that has the site logo to the left and nav to the right.
Please help.
Thanks.
Andrew
Hi there,
Try adding this CSS:
body.page-id-1205 .site-logo {
margin-left: auto;
}
Let me know if this helps :)
Genius! I had thought about looking for the page id, but couldn't find it for some reason.
That works. Thanks.
Andrew
It's always in the body tag:
https://www.screencast.com/t/AwPGaC3tuOW
Glad I could help :)