From b613ab037c2a9f1a1c79cb12e4141106c1a2d46b Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Wed, 8 Dec 2010 07:02:52 +0000 Subject: [PATCH] Use pagination base for CPT archives. props scribu, fixes #15728. git-svn-id: https://develop.svn.wordpress.org/trunk@16787 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/post.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-includes/post.php b/wp-includes/post.php index 916fc97875..8d649db193 100644 --- a/wp-includes/post.php +++ b/wp-includes/post.php @@ -985,7 +985,7 @@ function register_post_type($post_type, $args = array()) { $wp_rewrite->add_rule( "{$archive_slug}/$feeds/?$", "index.php?post_type=$post_type" . '&feed=$matches[1]', 'top' ); } if ( $args->rewrite['pages'] ) - $wp_rewrite->add_rule( "{$archive_slug}/page/([0-9]{1,})/?$", "index.php?post_type=$post_type" . '&paged=$matches[1]', 'top' ); + $wp_rewrite->add_rule( "{$archive_slug}/{$wp_rewrite->pagination_base}/([0-9]{1,})/?$", "index.php?post_type=$post_type" . '&paged=$matches[1]', 'top' ); } $wp_rewrite->add_permastruct($post_type, "{$args->rewrite['slug']}/%$post_type%", $args->rewrite['with_front'], $args->permalink_epmask);