is_feed
(one of the many conditional tags) can be used to determine if the current query is for a feed.
But how do I use it to target all category feeds? (or tag or custom taxonomy feeds for that matter)
This doesn’t seem right:
if (is_category()) {
if (is_feed()) {
// Code Goes here
}
}
And I have no clue as to whatelse I’d try.
If you want to determine if you are in a category feed, for example:
you can do so with
or
You can similarly check if you are in a tag feed, for example:
with
is_tag
.You can then check if you are in a custom taxonomy feed, for example:
with
is_tax
.