Archived topic
php post_class() issue
1 reply · Started by Emanuele on September 11, 2020
Hi everyone,
we have a strange problem with the string <? php post_class (); ?> and I can't understand what happened. Normally it returns all classes that belong to the post including categories and subcategories also in a custom post type we created with many taxonomies. After a further customization to filter between these posts taxonomies, the string <? Php post_class (); ?> returns only subcategories, so if a post has no subcategories then it returns nothing. What may have happened? Why does it only work partially? Is there a theme feature that expands its functionality? Thanks!
Hi there,
are these custom taxonomies ?
If so - maybe this stack overflow is relevant:
https://wordpress.stackexchange.com/a/109376
GP only filters the post_class to remove the .hentry class from pages - as seen here: