Hey, so I came across this problem earlier today and I solved it pretty easily, but saw that some threads had similar problems with no answer, so I thought I would share mine here to help others / maybe get a fix if there is something broken:
The problem: I use a custom layout for my custom post taxonomy "listing-categories". Tried to first use an archive view for this taxonomy, but it does not give the option of using infinite scrolling.
Then, I decided to create a view that has a filter: taxonomy "set by the current archive page". It was querying the right posts, BUT infinite scroll only loaded the first page. When I scrolled down, it reloaded and said "no items found".
THE FIX:
I fixed this problem by using the taxonomy filter: listing-categories are set by one view shortcode, and then the name of the taxonomy, listing-category-name equals the shortcode, wpvlistingcategory
But we're not done yet. I had to find a shortcode to output the name of the taxonomy on the archive page I am on. I didn't see a views output that could display that, so I searched the forums and found a custom function that could do that:
add_shortcode('wpv_show_curent_tax', 'wpv_show_curent_tax');
function wpv_show_curent_tax() {
if( is_tax() ) {
global $wp_query;
$term = $wp_query->get_queried_object();
return $term->name;
}
}
This shortcode, [wpv_show_current_tax] (make sure you add it into the 3rd party shortcodes in Toolset-Settings-Front End Content first) can be placed inside of my views argument to dynamically output the name of the taxonomy which the user is on, only showing those posts. Here is the view which is displayed on the layout used for my product-categories archives:
[wpv-view name="listings-categories" wpvlistingcategory="[wpv_show_curent_tax]" view_display="layout"]
Now my infinite scroll loads more than the first page and I am happy.
In theory, the query filter: taxonomy "set by the current archive page" should do the same thing, but for some reason it wasn't. Is there any explanation for that?