Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Automatic 301 redirect when URL-only title changed?
I have had article authors change the URL-only title once published (I know not a good practice) and in general I like to have the URL title keywords in the URL for SEO reasons.
My URLs also have the article ID, so I was wondering if there might be any plugins that could automatically generate a 301 redirect for the old URL to the new full URL based on the article ID?
Thanks!
-Mark
Offline
Re: Automatic 301 redirect when URL-only title changed?
zem_redirect was an excellent plugin for that, but it is no longer supported. It stills works with the 4.4.1 release though.
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
Re: Automatic 301 redirect when URL-only title changed?
colak wrote:
zem_redirect was an excellent plugin for that, but it is no longer supported. It stills works with the 4.4.1 release though.
Any idea if “zem_redirect” is compatible with “gbp_permanent_links?” Would be nice if gbp_permanent_links had this capability !
Offline
Re: Automatic 301 redirect when URL-only title changed?
mericson wrote:
I was wondering if there might be any plugins that could automatically generate a 301 redirect for the old URL to the new full URL based on the article ID?
It’s unreleased at the moment but there is (deep breath) smd_redirect in development. It works, it’s just not very pretty yet. And it’s supposed to work with gbp_permanent_links although I’ve not tested it extensively.
You can use simple fixed redirects or regexes to catch URLs matching a pattern and redirect them with placeholders. In that regard it’s pretty much identical in functionality to .htaccess redirects but without the actual need for modifying .htaccess.
Unlike htaccess though, it doesn’t do any of the modifiers like [L] and stuff so it can get in a loop if you’re not careful — and the order of the rules doesn’t matter, even though you can drag ‘n’ drop them: that’s all geared up ready for future functionality I haven’t figured out how to write yet!
But if that sounds like it might be of use in its present form I could send you the beta.
Last edited by Bloke (2011-12-08 21:27:09)
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Offline
Re: Automatic 301 redirect when URL-only title changed?
mericson wrote:
I have had article authors change the URL-only title once published (I know not a good practice) and in general I like to have the URL title keywords in the URL for SEO reasons.
My URLs also have the article ID, so I was wondering if there might be any plugins that could automatically generate a 301 redirect for the old URL to the new full URL based on the article ID?
In my section/id/url-title installation a change of url-title in the URL still pulls the correct article. I am not sure if this still works if you use the old URL but change the article field ‘url-title’.
Maybe you don’t even need the 301 :)
Working examples:
Original URL: http://sankt-georg.info/artikel/979/zeitumstellung-sommerzeit-winterzeit-normalzeit
Edited URL: http://sankt-georg.info/artikel/979/sommerzeit-normalzeit
Wrong section: http://sankt-georg.info/sammlung/979/sommerzeit-normalzeit
Not sure (in my configuration) why the last one works and/but renders the article excerpt
Get all online mentions of Textpattern via OPML subscription: TXP Info Sources: Textpattern RSS feeds as dynamic OPML
Offline
Re: Automatic 301 redirect when URL-only title changed?
Bloke wrote:
It’s unreleased at the moment but there is (deep breath) smd_redirect in development.
/* keeps eye peeled */
Offline