I recently migrated my website – and part of this migration was changing from static html to a wordpress website. All of my links to my site still use the following scheme: mysite.com/{year}/{month}/somepost.html
whereas my new scheme is mysite.com/{year}/{month}/somepost/
How can I redirect (301) using mod_rewrite all URLs with the old pattern to the new one?
Using mod_rewrite you can set your .htaccess file to redirect the incoming links from
http://example.com/2004/04/title_of_post.html
tohttp://example.com/2004/04/title-of-post/
by:There is also a plugin for wordpress, you may have a look link