Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I have created two custom post types, each with it's own slug. Each custom post type contains some articles with the same title.

So ideally I would have . .

customposttype1/mainarticle/

customposttype2/mainarticle/

Instead I get . . .

customposttype1/mainarticle/

customposttype2/mainarticle2/ <-- with the extra 2 on the end

The permalinks are set to "postname".

Any help would be appreciated.

share|improve this question
add comment

1 Answer 1

This is normal WordPress behaviour. Any time it detects that a slug is a duplicate - regardless of post-type or parents or categories - it will append a number to differentiate the newer version. As far as I know, there is no way to override this.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.