Archived topic
Exclude background from pages using css
3 replies · Started by Dave on April 6, 2016
I'm using the background addon for most of the pages on a site, but there are a few pages I'd like different headers on. How can I exclude the background from those pages using css?
Hi Dave,
Find the page IDs for these specific pages, then add this CSS:
body.page-id-xx {
background-image: none;
}
xx being the ID of the page.
Let me know if you need more info :)
Thanks Tom,
Still unable to switch headers/backgrounds. I'm working on localhost, so it's difficult to show where I'm at. One thing I've noticed is that when I attempt to change header image on any page, I'm not getting the switches shown in the videos. Specifically, I don't see anything for "merge with site header."
I realise I haven't given you a great deal of info, but, any hints where I might look to troubleshoot?
I just released a new version of my Simple CSS plugin which has a metabox you can add CSS to for specific pages: https://wordpress.org/plugins/simple-css/
So while editing your page, you would just add this into the metabox:
body {
background-image: none;
}
That would remove it completely.
The "Merge with site header" options will only show up if you have content added into the Content field.
