To get the category object use get_category
(codex). It’s easy if you know the name, slug or ID, but if you don’t you could use is_category
to check on which category you are and pass the ID to get_category
.
To get the category object use get_category
(codex). It’s easy if you know the name, slug or ID, but if you don’t you could use is_category
to check on which category you are and pass the ID to get_category
.