[SOLVED] Add a Post’s Category Name to Body Class
Hi from Russia.
How to Add a Post’s Category Name to Body Class? I need it for customize menu. I found only this example: Code:
function add_category_name($classes = '') { |
Where did the place you found the code snippet suggest you put it?
Did you try it? |
Here
I did not try, because I do not know where to insert this code. |
That link tells you where to put the snippet.
|
Thanks!!! It works!!! Now in body classes i can see class - "category-name" and in css i added some style for this category. Cool!!!
|
All times are GMT -6. The time now is 03:01 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.