Tagged: categories, custom.css, minor meta, post
-
AuthorPosts
-
December 16, 2017 at 7:42 pm #889650
Hi guys,
I’d like to add custom CSS classes to different post categories so I can customize each one of them one by one. I am talking about the minor meta here that shows below each post’s image. I’ll have around 3-4 categories that need to have custom CSS added to it.
See this screenshot below so you can get an idea what I’m talking about;
How could I achieve this?
Many thanks in advance,
– MarkDecember 16, 2017 at 9:01 pm #889687Hey paperdog2,
Unfortunately, it would require quite some time and customization of the theme to achieve this, so I am sorry to tell you that this is not covered by our support. However, if it’s really important for you to get this done, you can always hire a freelancer to do the job for you :)Best regards,
MikeDecember 16, 2017 at 10:28 pm #889709Thank you for the quick response Mike!
I really appreciate it, although I would need the exact same thing as this one, but that code doesn’t really seem to be working for me;Enfold Different Styles of Categories
Is there any way you guys could assist me with this?
Many thanks,
– Mark- This reply was modified 7 years ago by paperdog2.
December 17, 2017 at 12:24 am #889722Hi,
The code didn’t work for me ether, but I will ask Ismael to take a look.Best regards,
MikeDecember 18, 2017 at 2:04 am #889878December 18, 2017 at 11:14 am #889965This reply has been marked as private.December 18, 2017 at 9:14 pm #890244Hi Mark,
Using a JavaScript solution is not a good option here, you should make changes in the templates or try something like this
.blog-categories.minor-meta a:nth-child(n) { background-color: red; } .blog-categories.minor-meta a:nth-child(2n+1) { background-color: blue; } .blog-categories.minor-meta a:nth-child(3n+1) { background-color: green; }
Best regards,
VictoriaDecember 19, 2017 at 11:25 am #890410This reply has been marked as private.December 20, 2017 at 3:03 pm #890786Hi Mark,
If this is a category page, you should be looking at archive.php and look where categories are rendered.
Best regards,
Victoria -
AuthorPosts
- You must be logged in to reply to this topic.