WordPress.org

Make WordPress Core

Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#33722 closed defect (bug) (invalid)

Release Slugs On Post/Page Removal

Reported by: atomicjack Owned by:
Milestone: Priority: normal
Severity: normal Version: 4.4
Component: Permalinks Keywords:
Focuses: Cc:

Description

Hi,

When a post or page is created with the same title, it adds a number on to the end of the slug, however, if you go to delete these posts/pages, it won't 'release' the slug, it will keep incrementing if you create another post/page with the same title.

Whilst it is not a major issue, it makes it more difficult for the end-user to create the correct slugs. They may have accidentally created /events/ in the past, but then decided 'oh I don't want that', deleted it, then a couple years later wanted it back... except, they can't. It will always increment the number.

Relevant: https://wordpress.org/ideas/topic/make-slug-collisions-more-obvious

Change History (4)

#1 @atomicjack
6 years ago

I'm undecided on whether to class this as a defect or enhancement... please update if necessary.

#2 follow-up: @GaryJ
6 years ago

  • Keywords close added

What you're describing you want is the default behaviour already, if the post is also emptied from the trash too. Until that it is done, it could be restored, so the slug is still reserved. Once the trash is emptied, the slug is available again, without having to add or increment the suffix.

#3 in reply to: ↑ 2 @atomicjack
6 years ago

  • Resolution set to invalid
  • Status changed from new to closed

Replying to GaryJ:

What you're describing you want is the default behaviour already, if the post is also emptied from the trash too. Until that it is done, it could be restored, so the slug is still reserved. Once the trash is emptied, the slug is available again, without having to add or increment the suffix.

Ah. Got it. I didn't think about the trash!

#4 @chriscct7
6 years ago

  • Keywords close removed
  • Milestone Awaiting Review deleted
Note: See TracTickets for help on using tickets.