[wp-trac] [WordPress Trac] #18962: Allow duplicate slugs for different content
WordPress Trac
noreply at wordpress.org
Thu Sep 11 19:03:49 UTC 2014
#18962: Allow duplicate slugs for different content
---------------------------------------------+------------------
Reporter: maorb | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 4.1
Component: Permalinks | Version: 2.9
Severity: major | Resolution:
Keywords: has-patch commit has-unit-tests | Focuses:
---------------------------------------------+------------------
Changes (by nacin):
* keywords: has-patch needs-testing => has-patch commit has-unit-tests
* component: Rewrite Rules => Permalinks
* milestone: Future Release => 4.1
Comment:
Replying to [comment:14 SergeyBiryukov]:
> Replying to [comment:13 mboynes]:
> > Can someone please explain why `wp_unique_post_slug` works the way it
does with regards to hierarchical custom post types versus non-
hierarchical custom post types?
>
> Introduced in [11125] as a fix for page/attachment slug conflicts in
#6437.
>
> [21845] (#15665) was a more recent fix. Perhaps [11125] can be reverted
now.
I've traced this same history and I concur with this finding. It should
never have been turned into what it is now.
I'm going to upload a new patch with some basic tests. If someone wants to
expand on this, that's fine. Honestly, the only way this can go wrong if
two post types share the same rewrite base, and or have their rewrite base
removed, and that's going to have problems at the rewrite level, not just
this level.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/18962#comment:32>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list