I am trying to move away from having dates in my permalinks since they serve no purpose on my site. I am having trouble with a RewriteRule to redirect old permalinks.
I would like http://www.mydomain.com/2008/07/19/my-post-title/ to redirect to http://www.mydomain.com/my-post-title/
The rule I have been trying is
RewriteRule ^([0-9]{4})/([0-9]+)/([0-9]+)/([^/]+)/*$ http://www.mydomain.com/$4/ [L,R=301]
But that ends up as a 500 Server Error because the redirect never completes (loops).
I can change the redirect from $4 to $1 and the post is redirected to /2008/, same for $2 and $3. $4 always time-out.
Any ideas?
Thanks