Treehouse: Grow your CSS skills. Land your dream job.

Blogger to WordPress 301 redirects.

  • # April 7, 2012 at 1:42 pm

    I’m working on moving a blog from blogger “using a custom domain name not” to a self-hosted WordPress using the same domain name.

    But the permalink structure is going to change from blogger’s “/year/month/post.html” to “/post” in WordPress, So how can I edit the .htaccess to redirect all old posts “250+” to their new URLs?

    I know that it will looks like this

    Redirect 301 /oldpage.html

    but I think I need some RegEx to filter the URLs . So this is the part I need help with?


    # April 7, 2012 at 8:38 pm

    Here is what I used when transferring mine from blogger to wordpress.

    RewriteEngine On
    RewriteBase /
    RewriteRule ^([0-9]{4})/([0-9]{1,2})/([^/]+).html$ $1/$2/$3/ [QSA,R=301,L]

    # April 15, 2012 at 12:01 pm

    Thanks it worked but I just modified it a little & removed ($1/$2) to match my new format.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.