Update: b2evolution to WordPress migration

This is an update to previous post.

Since this blog was migrated successfully from b2evolution to WordPress, I decided to migrate another blog. More issues noticed with that particular migration. The blog was at a bigger scale and it’s too much work to fix issues manually. Therefore I decided to get my hands dirty to hack the script to make it work for me.

Issues with the script

Issues I had, including the issues I had last time:

  • Pages were imported as posts
  • Slugs were not imported
  • Created date was used as published date
  • Deprecated posts and comments becomes Published

Updated Script

The script is updated to fix the above issues.

Credit goes to GG the original author of the script who kindly shared the code and KP who adapted the code for b2evolution V5.1.2. The script is based on the adapted code and has been tested with migration from b2evolution V5.2.2 to WordPress V4.4.2.

As with Deprecated posts and comments, since WordPress does not come with ‘Deprecated’ status, they become Draft in WordPress after migration. You can customize status in WordPress but I’ve not tried it yet.

The script is available for download.

Note: this is not a plugin!

This is a script you upload to your site’s home directory (where wp-config.php is) and access via browser. (Refer to original instruction.)

Important: Make sure you backup your database before you do this! And remember to remove the file after migration is done.

The script can be run on a fresh WordPress install or merged into an existing WordPress site. I’v tried both with success.

Disclaimer

Run at your own risk. 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *