Change number of posts to display

enchance picture enchance · Apr 19, 2012 · Viewed 17.3k times · Source

How do I tell Wordpress to change the number of posts to display depending on the type of page being shown? For example, all Search results will show 10 posts at a time while Archives will show 20 posts at a time, etc.

Answer

janw picture janw · Apr 19, 2012

This should be moved to https://wordpress.stackexchange.com/
There is 1 global setting (settings->reading)

If you want to change individual settings you will have to adjust your theme.
put query_posts('post_per_page=XX') before the loop also look at: query_posts