I have a Django CMS site, which is currently configured to display in multiple languages - I am in the process of converting this to a single-language site.
As such I need to disable the Django MultilingualURLMiddleware, but I want the old /en/ URLs to resolve and redirect to the new URLs, so that any cached/bookmarked links with behave sensibly and I don't lose the Google Page Rank for the existing pages.
How do we do this? Easy, via an Apache RewriteRule:
RewriteRule ^/en/(.*) /$1 [R=301,L]
Thanks to Benjamin Wohlwend for his solution.
No comments:
Post a Comment