I've searched quite extensively for a solution to this, and none of the solutions seem to fix the problem. Hoping that I may be missing something that somebody will catch.
I'm using Events Manager and the Structure theme. I'm trying to combine EM events (a custom post type) with regular posts on the homepage. Pagination fine for as many pages as a regular post appears on, but breaks as soon as there's a page with only events.
I have tried turning off permalinks, toggling them off and on. I've made sure there's no Page called "event". I'm making sure there's a 'paged' variable. I've set the Settings > Reading post number to 1 (there's a separate option provided by the theme, seen below.)
Here's the part of home.php that's setting up the query:
<?php // customizing arguments for WP_Query - altering the query so that both 'event' and regular post types are supported $paged = (get_query_var('paged')) ? get_query_var('paged') : 1; $home_args = array( 'post_type'=>array('post','event'), 'tax_query'=>array( 'relation' => 'OR', array( 'taxonomy' => 'event-categories', 'field' => 'id', 'terms' => of_get_option('category_home_event'), ), array( 'taxonomy' => 'category', 'field' => 'id', 'terms' => of_get_option('category_home'), ), ), 'posts_per_page' => of_get_option('postnumber_home'), 'paged' => $paged, ); $wp_query = new WP_Query($home_args);
Any help much appreciated!