[wp-hackers] Need Custom Post Type Rewrite Help, Please
scribu
scribu at gmail.com
Sun Apr 18 10:49:50 UTC 2010
On Sun, Apr 18, 2010 at 1:37 PM, Mike Schinkel
<mikeschinkel at newclarity.net>wrote:
> $pages = get_pages();
> foreach ( $pages as $page )
>
> $wp_rewrite->add_rule("$page->post_name/?","index.php?post_type=page&p={$page->ID}",'top');
>
> Only problem is, in either case, now it calls single_template instead of
> page_template. Go figure.
>
You should use *?page_id=* instead of *post_type=page&p=*
--
http://scribu.net
More information about the wp-hackers
mailing list