devinsays/portfolio-press — Issue #20: Posts Per Page on Portfolio Taxonomies
Author: devinsays
Created: 2012-03-07 05:08:06+00:00
State: open

function wpt_portfolio_custom_posts_per_page( $query ) {
global $wp_the_query;
if ( $wp_the_query === $query && !is_admin() && is_post_type_archive( 'portfolio' ) ) {
$query->set( 'posts_per_page', '9' );
}
}