Make WordPress Core

Opened 16 years ago

Closed 16 years ago

Last modified 16 years ago

#7805 closed defect (bug) (fixed)

Permalink doesn't update with new title on 'pending' posts.

Reported by: jeremyclarke's profile jeremyclarke Owned by: markjaquith's profile markjaquith
Milestone: 2.7 Priority: normal
Severity: normal Version: 2.7
Component: General Keywords:
Focuses: Cc:

Description

right now when you save a post as draft, then edit the title, the permalink is automatically changed to be the slug version of the new title. You can also manually edit it.

Once the post is published the slug is set and you have to manually change it.

However, if you save your post as 'pending' (by submitting it for review, which is what people who don't have publishing capabilities do when they use the publish button) then someone changes the title after, it doesn't alter the permalink, it keeps the slug from the old title.

So if an editor changes the title while editing the post (a common thing) they have to manually change the permalink, which is not only annoying, but confusing because they are used to how the permalinks work when they are editing their own posts, and they don't expect that it would be different.

Is this intentional? It doesn't make very much sense to me conceptually, and practically it has terrible implications (i don't even want to think about how many posts in our site have been affected by this that we just never noticed.)

I'll look into this soon anyway, but let me know if it's intended behavior (so I can debate more!)

Change History (5)

#1 @jeremyclarke
16 years ago

  • Cc jeremyclarke added

#2 @markjaquith
16 years ago

  • Owner changed from anonymous to markjaquith
  • Status changed from new to assigned

I've noticed this also. I don't like the behavior. A Pending Review post is going to an Editor for review. If they change the title (which is a common task for an Editor), the slug should update.

#3 @markjaquith
16 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [9055]) Do not allow contributors to set the post slug for pending review posts. fixes #7805

#4 @markjaquith
16 years ago

That commit blanks the slug if a post is being put into pending review status by someone without the publish_posts capability, and doesn't even show the edit fields to them once it is in pending review status.

#5 @jeremyclarke
16 years ago

Perfect, thanks Mark!

Not a real problem but there's a typo in one of the comments " Don't allow contributors to set to set the post slug".

Note: See TracTickets for help on using tickets.