I’m having trouble displaying any more than around 70 posts on one page for some reason and it seems to have only happened after updating to the latest version of WordPress. I need to display every single post (over 1500 of them) on my sitemap page and also another page.
I am using the code below but it isn’t working
wp_reset_query(); $result = new WP_Query('posts_per_page=-1');
I’ve also tried using the below code as well as
$result = new WP_Query('posts_per_page=1500’);
But any number over 70 and I just get a blank white page.
Anybody know why this may be? It was all working perfectly until I did some updates to plugins and to WordPress.
- The topic ‘Can't display all posts on a page’ is closed to new replies.