Archived topic
Category - Colored Meta on Blog Archive
5 replies · Started by Patrick on March 8, 2019
Hi, wasn't able to find a solution anywhere.
I want to change the color depending on the category name meta on the Blog Archive page. So make "News" orange for example and Guides blue, etc. (http://prntscr.com/mv1fbi)
When I check the inspector there is no class or id for each category.
Thanks in advance
Hi there,
how many categories do you have on each Post? Is it more than one ?
Well I will have around 4 Categories, and it would be nice if on the blog archive page each category would have a different color.
Here is an Example Website that does that: https://www.gamezebo.com/
They have "News" in orange and "Walkthroughs" is an other color.
The post article iteslf carries the category class so this would style the cat link on the archives for that particular category-slug:
:not(.single-post) .category-slug .cat-links a {
background-color: red;
padding: 4px;
color: #fff;
}
Ahh thanks thats exactly what I wanted
Awesome - glad to be of help