301 redirect – Tumblr to WordPress

I’ve moved a blog from tumblr to wordpress, so far only the posts has been imported to the new wordpress setup. What’s left is to do the 301 redirects.

I have more than little knowledge about this so therefore I need a little help. A posts url in tumblr looks like this:

Read More

example.com/post/[ID]/post-slug

And in wordpress like this:

example.com/2012/04/07/post-slug

The post slug is equal so I guess there should be a way to accomplish this. Oh and if it matters, the domain is the same.

Related posts

Leave a Reply

1 comment

  1. I solved it myself using this piece of code:

    RewriteRule ^/post/(.*?)/(.*?)$ /$2 [R=301,L]
    

    But as I said, I’m not good at this so if anyone has something better, tell me.