Saturday, 5 December 2015

How do I get current taxonomy "term id" on wordpress?

$obj = get_queried_object();
echo $obj->term_id;

No comments:

Post a Comment