For this kind of rewriting, I'm using this code (haven't tested this one exactly, so may contain minor bugs):
add_filter( 'query_vars', 'binda_query_vars' );
function binda_query_vars( $vars ) {
$vars[] = 'pp';
return $vars;
}
add_action( 'generate_rewrite_rules', 'binda_rewrite_rules' );
function binda_rewrite_rules( $wp_rewrite )
{
$wp_rewrite->rules = array(
'news/([0-9]{1,})/([0-9]{1,})/?$' => $wp_rewrite->index . '?post_type=news' . '&pp=' . $wp_rewrite->preg_index( 1 ) . '&paged=' . $wp_rewrite->preg_index( 2 ),
'news/([0-9]{1,})/?$' => $wp_rewrite->index . '?post_type=news' . '&pp=' . $wp_rewrite->preg_index( 1 ),
'product-list/([0-9]{1,})/([0-9]{1,})/?$' => $wp_rewrite->index . '?post_type=product' . '&pp=' . $wp_rewrite->preg_index( 1 ) . '&paged=' . $wp_rewrite->preg_index( 2 ),
'product-list/([0-9]{1,})/?$' => $wp_rewrite->index . '?post_type=product' . '&pp=' . $wp_rewrite->preg_index( 1 ),
) + $wp_rewrite->rules;
}
You may need to replace post_type=news and post_type=product for appropriate post_type created in your system.
Note that this does not replace your permalinks in a template, you have to do that manually.