Hi
I’m about to launch an updated version of an old site.
I need to redirect old posts to the same posts (but a different permalink structure) on the new site. This is just to cover old links which my be out in the wild on other sites, or bookmarked, so they don’t get a 404.
The permalinks structure has changed, from domain/year/month/post-title to just domain/post-title, and all post titles are the same as they were – it’s just the path that needs changed.
I’ve had a look here but can’t see anything directly related. How would I accomplish this? I understand the rule would need to be this:
RedirectMatch 301 ^/([0-9]{4})/([0-9]{2})/([0-9]{2})/(.*)$ http://www.yourwebsite.com/$4
or possibly this:
RedirectMatch 301 ^/([0-9]{4})/([0-9]{2})/(?!page/)(.+)$ YOUR-DOMAIN/$3
with the domain changed to match the site but I’m not sure if that’s the correct way to add it to BPS, or which one of these to use. Please advise.