Serving The Planet

Convert WordPress xml to Blogger xml

I’m pretty sure I’ve got this covered somewhere on my blog, but unable to find my own blogpost :-) Must be because of switching domains for my blog and Google’s indexi not having caught up yet. Ah here it is.

Hmz. Anyway … I finally found my old tell-a-few.com 2010 blog SQL dump with blogposts going as far back as 2001!

Did you enjoy this article?
Signup today and receive free updates straight in your inbox. We will never share or sell your email address.
I agree to have my personal information transfered to GetResponse ( more information )

However trying to import that directly into Blogger won’t work. So … I setup a local webserver environment with XAMPP, imported the SQL dump into an fresh WordPress 2.9.2 installation (what I think I was running at the time).

Now trying to access a blog gives an error. Of course you first have to edit the wp_options table and reset the admin login, before you’re able to access the backend … with 1000+ blog posts! Next step … exporting.

Go to tools, export and download the export file. This gives you a XML file … however file format is WordPress it’s own WXR (Wordpress eXtended RSS). You cannot import this into blogger, and although this online WXR to Blogger converter works great, it also has a file-size limit of 1MB. And my file dump is close to 3MB. Of course I can try to split it, which takes a lot of manual labor. OR I find a different and/or faster solution. So I gave the ‘Google Blog Converters AppEngine’ a try. Just download and unpack it (into an easy to access directory). Now the ‘tough part’; open a command line, and access the directory with the bin files, and run the “wordpress2blogger.bat” file. Python error. Hmz, should work out of the box. Not in the mood for troubleshooting this, so booted to Mac OSX.

Ran the scrip bin/wordpress2blogger.sh wp2010.xml … and get an error: “Import WordPress Document is not valid”. Troubleshooting links with similar issues.

So basically WordPress has wrong CDATA formatting. *sigh* What’s that saying again from Jim Rohn? “Don’t wish life were easier, wish you were better!” Myeah. Booting back to Windows, upgraded WP 2.9.2 to latest version. Deleted all pages and comments. Exported the new posts file. Ran the conversion script. WORKS! BTW? It outputs the conversion to the screen. So you’re better of running: bin/wordpress2blogger.sh wp2010.xml >new.xml

That’s it? Nope, we’re not finished yet. Search & replace for about 2100 old domain links, into new links. Oh LOL. Analysing the contents of the export makes me both laugh and cry at the same time. A ton of deeplinks that are not going to work after importing, a lot of youtube videos won’t play (because of using special wordpress youtube plugins), etc. etc. At least my blog has grown from close to 500 to 1500+ posts! Going back as far 2001(!)

How much time I spend at this? Close to 7 hours, but it was worth it!

About Earnie Rhyker

tech pioneer | intellectual BadAss | ethical lifehacker | WordPress Developer & Polyglot | information activist | blogger | added value services provider | multimedia enthusiast | senior linux server administrator | geek | bitcoin investor | laptop entrepreneur | open source contributor | hackintosh fanatic | charity donator | accredited top MLM networker & internet marketer 2014-2016 @ BFH | digital expat

View All Posts

Communities I have been 'hanging out' regularly over the past two decades. 

Note: links go to my profile on those respective sites. Connect with me if you like.

 

, ,

Earn With Earnie

This site hasn't been updated since 2022. Visit my new blog -- EarnWithEarnie.com -- instead:

X
error: Content is DCMA protected !!
Skip to content