#3202 closed enhancement (fixed)
"Redirect Old Slugs" should be in core.
Reported by: | bryanveloso | Owned by: | markjaquith |
---|---|---|---|
Milestone: | 2.1 | Priority: | normal |
Severity: | normal | Version: | 2.1 |
Component: | Administration | Keywords: | has-patch 2nd-opinion |
Focuses: | Cc: |
Description
http://txfx.net/code/wordpress/redirect-old-slugs/
Simply, this should be in core, there's no reason why any WP installation should be without this.
Attachments (1)
Change History (12)
#2
@
18 years ago
- Keywords has-patch 2nd-opinion added
Patch is up.
- New meta key (_wp_old_slug) which will be hidden (it should just WORK without people even seeing it)
- People who were using the plugin will have their old slugs updated to the new meta key on upgrade
- uses wp_redirect($link, '301') now
- Only works on posts. There doesn't seem to be a clean way of recognizing failed Page attempts... of course there is always my "Page Links To" plugin to take care of that. ;-)
- Works completely through filters.
I'm obviously biased, so I'm going to need some +1's here
#6
@
18 years ago
If you're going to commit this, can you also make the slug automatically update to reflect the post title when the post title is changed? I believe the reason the slug wasn't updated to reflect an updated post title was to not break links, but if this is committed, that won't be an issue.
#7
@
18 years ago
JeremyVisser,
Hm, probably not a great idea. It'd cause a lot of unnecessary redirects. Take for instance the rather common practice of updating "Post Title" to "Post Title (UPDATED!)" ... that shouldn't cause a slug change, because, well, it doesn't make sense to have "updated" in the slug, it'll break caching, and it could cause the link to lose a bit of Google juice.
#9
@
18 years ago
- Resolution fixed deleted
- Status changed from closed to reopened
I see this when updating the slug on a published post.
Warning: in_array() [function.in-array]: Wrong datatype for second argument in /var/www/weblog/wp-admin/admin-functions.php on line 2094
You're just saying that because I have commit access. :-P
Okay, I can't lie. It's a brilliant plugin, and you're right.