Sorry for opening this thread again, but this is something which really haunts me.
What I’ve done so far:
I put this code in the functions.php:
add_action('init', 'my_em_taxonomies');
function my_em_taxonomies() {
register_taxonomy_for_object_type('post_tag', EM_POST_TYPE_EVENT);
register_taxonomy_for_object_type('category', EM_POST_TYPE_EVENT);
}
I put this filter after it:
add_filter( 'pre_get_posts', 'my_get_posts' );
function my_get_posts( $query ) {
if ( is_home() && $query->is_main_query() )
$query->set( 'post_type', array( 'post', 'event' ) );
return $query;
}
But the event still doesn’t show up on the homepage. Where did I go wrong? Or what did I miss?
Thanks for helping. Problem is my site basically exists only of events. At the monent I have to copy every event to show up as post which is very time consuming.