Events not show in categories
-
Hello,
with this code in function.php
// Registra Categorie WP nell’inserimento Eventi/Location
function my_em_own_taxonomy_register(){
register_taxonomy_for_object_type(‘category’,EM_POST_TYPE_EVENT);
}//CPT EM
add_filter( ‘pre_get_posts’, ‘my_get_posts’ );function my_get_posts( $query ) {
if ( is_home() && false == $query->query_vars[‘suppress_filters’] )
$query->set( ‘post_type’, array(‘post’, ‘page’, ‘album’, ‘movie’, ‘quote’, ‘event’, ‘attachment’ ) );
return $query;
}I correctly see the events on the home page with te normal posts but I can’t see them in single WP categories
Can you help me ?
Thanks, Fabrizio
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Events not show in categories’ is closed to new replies.