Pagination and query_posts()

There is an error in the WordPress codex regarding pagination in query_posts(). It says that as of WordPress 3.0.2, the parameter name in get_query_var() is called ‘page’. This is incorrect and will result in the same posts appearing regardless of the page number.

Use get_query_var('paged') instead.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s