Forum Replies Created

Viewing 1 replies (of 1 total)
  • Thread Starter steffenms

    (@steffenms)

    Hi,

    Thanks for your answer. This is a theme related issue, as TEC works fine with other themes, I hoped to find someone with a solution over here.

    However, with the help of the other forums I came up with a solution for this:
    I only tried it briefly, but it seems to work:

    Put this code into the functions.php of the Hueman theme. Please remark the custom post type of TEC named tribe_events which is added to the main blog by this.

    function my_post_queries( $query ) {
      // not an admin page and is the main query
      if (!is_admin() && $query->is_main_query()){
        // query the home page
        if(is_home()){
          $query->set('post_type', array('post','tribe_events'));
        }
      }
    }
    add_action( 'pre_get_posts', 'my_post_queries' );
Viewing 1 replies (of 1 total)