[wp-trac] [WordPress Trac] #18594: Permalinks should be saved twice on post_type slug change
WordPress Trac
wp-trac at lists.automattic.com
Fri Feb 10 11:40:58 UTC 2012
#18594: Permalinks should be saved twice on post_type slug change
--------------------------+------------------------------
Reporter: Gecka | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Permalinks | Version: 3.2.1
Severity: normal | Resolution:
Keywords: close |
--------------------------+------------------------------
Changes (by duck_):
* keywords: => close
* severity: critical => normal
Comment:
It sounds like the problem is that you're flushing the rewrite rules but
with the old custom post type information still registered. The fix would
be to re-register your post type after updating the option, e.g.
{{{
update_option( 'my_post_type_slug', $slug );
my_post_registration(); // calls register_post_type(), usually hooked into
init
flush_rewrite_rules();
}}}
I think there must be another ticket somewhere about this on Trac, but I
couldn't find it just now.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/18594#comment:4>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list