Mar 31 2007
How to Move from Movable Type 3.34 to WordPress 2.1.2 With Lots of Entries
After banging my stupid head against the wall like an idiot last night, I settled in, figured it out, and now it’s all working. Here’s how you do it:
Before you start, understand what these instructions are for:
These instructions assume you’re moving from Movable Type 3.34 to WordPress 2.1.2 or later AND that you have no customized WordPress content (why would you? You’re switching!). ON steps where I tell you to delete stuff, you can always download it and save it for a rainy day.
1. Inside Movable Type, go to Import / Export. Export your file and download it to your desktop. You should have a file called Import.txt. That file is all your entries, comments, pingbacks, trackbacks, and so on. Open that file in a quality text editor and save it as UTF-8 format. That will keep your special characters in place and save you a ton of problems later on. If you don’t do this, your quotes and such will be replaced with various cruft.
2. Delete your entire MT installation. You don’t need it anymore.
3. Install WordPress 1.5.2. Why, you ask? Because the instructions on the WordPress site are so hopelessly out of date that they don’t work with any of the newer versions, but they work just fine with 1.5.2.
4a. If you have server root access, edit PHP.ini to change the Script Memory. Assuming you have a large file of imports (bigger than 5 megs) change it to 100 megabytes. Restart Apache. Don’t forget to change this back after you’re all done!
4b. If you don’t have root access, split your file appropriately. The WordPress importer is smart enough to not overwrite entries it already imported, just make sure you keep your entries in the split files together.
5. Copy the file import-mt.php to your desktop. It’s in your installed folder under wp-admin/import. In the folder change the line that says define(’MTEXPORT’, ); to define(’MTEXPORT’, ‘import.txt’); where import.txt is the file name you chose for your entries file. Take that file and upload it into wp-admin.
6. Log into Wordpress (http://www.domainname.com/wp-login.php)
7. Go to http://www.domainname.com/wp-admin/import-mt.php
8. Click the link that says Let’s Go
9. On the next page, you’ll see an author mapping table. Map the authors from your file to the authors you have in WordPress appropriately.
10. Click Submit.
11. The system will start parsing the file. One by one you should see something like “Entry: Entry name, Comment Posted, Comment Posted, Comment posted, comment posted”. Let that roll. It’s gonna take awhile.
12. After a few minutes, you’ll see a link that says Have Fun. You’re not ready to have fun yet. You have some work to do, dammit!
13. Go into your installed WordPress folder and wipe out your WordPress installation. Erase every folder that was installed with WordPress and every file. I promise you don’t need them anymore.
14. Download WordPress 2.1.2. Change the wp-config-sample.php to wp-config.php and edit it appropriately using the settings for your existing MySQL database. Now that you’ve done that, upload everything into the appropriate folders on your server.
15. Run http://www.domainname.com/wp-admin/upgrade.php
16. Verify that everything is working and that your entries have moved over.
17. Once everything is working, go into PHPMyAdmin and delete your MT database.
I understand that WordPress includes an importer in 2.0 and later, however, that importer is a pain in the butt and will choke on a MT import file bigger than 2 megabytes. I can’t imagine people having anything that small, but if you do, just use it. This method worked with my import file which was 17.5 megs. It’s a bit roundabout, but it does work as evidenced by the fact that I’m up and running today!
Happy hacking!
Technorati Tags: wordpress, movable type

May 23rd, 2007 at 10:50 am
Your ‘how-to’ is really clear. Thank you.
However, I am moving from (i am an average tech-head and want less to manage!!) paid-hosted Movable Type 3.2 to free hosted Wordpress.
How would I import my MT3.2 entries, comments etc into my Wordpress blog?
Thanks.