Styling by Category on Posts Page

Posted in: Newspaper
Post count: 4

Hello,

I would like to style posts that have a certain category differently, so that it’s broken up visually on posts page that are displaying multiple categories.

Normally, WP has a class for the category on any particular article element, but it seems as if the Newspaper theme overrides this.

This seems to only be true for pages with the “latest articles” template – the main “posts” page of the site seems to have category classes normally.

I’m wondering if I’m missing something here, or if you can make any suggestions.

Thank you,

Greg

  • This topic was modified 8 years by greg-2.
  • This topic was modified 8 years by greg-2.
Post count: 20688

Hi,

The categories and also tags in which the post is included are displayed as classes for the article
https://www.screencast.com/t/aKvbKbBdnIF
Maybe that is useful to you, depending on what exactly you want to do. Also the post ID and the post template used are displayed as classes on the body
https://www.screencast.com/t/z8JW4I8CpqaU
That would also be useful when you want to affect posts with specific post templates, or only one post by ID.
Please correct me if I misunderstand what you are asking.

Thanks

Viewing 2 posts - 1 through 2 (of 2 total)
The forum ‘Newspaper’ is closed to new topics and replies.