• For some reason the_category() is calling category #8 when it’s on the home page. Has anyone had this problem before? It’s driving me buts!

Viewing 1 replies (of 1 total)
  • Thread Starter jwerre

    (@jwerre)

    I found the problem. my first post on the home page was in category 8 so the home page was considered to be part of that category

    solution:

    <? if( in_category(8) && !is_front_page() ){ echo 'current_category'; } ?>

Viewing 1 replies (of 1 total)

The topic ‘the_category() isn’t working’ is closed to new replies.