Site logo

Archived topic

Page specific styling don't work if the page is selected as posts page

7 replies · Started by Dalibor on July 29, 2022

Viewing posts 1–8 of 8

I've tried various solutions from Simple CSS, to HFCM and page-specific additional CSS- nothing works.
If I try to style a specific page, that is selected as a posts page (settings/reading), NONE of the CSS changes will be applied to the page.
When I replace that specific page with another (dummy page) on the settings/reading as a post page, the styling changes are immediately live and visible.

I believe that I had a similar issue with the 'shop' page in the past (on another website).

As I don't like my solution of replacing the page with a 'dummy' page, I'd like to get to the bottom of this.

Edit: It has nothing to do with code overrides (!important), the CSS changes are not visible at all in a dev console.

Sure, pages linked.

Hi there,

the page that is set to display your latest posts ( a.k.a the Blog ) is not a normal page. WordPress ignores any Meta Boxes in the editor for that page, including Simple CSS.

So that CSS would need to go in your Simple CSS that is accessible from the dasboard.
And to target just the blog page you can use the .blog selector.

eg.


.blog .footer-widgets {
    /* your blog page footer widget styles */
}

You need to add the CSS in Appearance > Simple CSS or in the Customizer > Simple CSS.

That worked, thanks.

You're welcome

This archived topic is closed to new replies.