Different styling based on category
-
Hi!
Please help!
I’m trying to make my posts style differently based on the category!
I need a help with the code!
I know how to change the style using Post ID – I add the following line in the Single.php
<div class=”post” id=”post-<?php the_ID(); ?>”>
and it works perfect! Now I need to change the_ID() to a code that would reference the category! I tried the_category(), but that made the category appear!Please help!
Thanks!
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Different styling based on category’ is closed to new replies.