Upgrade WordPress From 2.12 to 2.50 to Prevent Being Hacked
April 19th, 2008 by Andrew Chen
I did not want to upgrade WordPress originally because upgrading WordPress has never been easy. It took me about one working day (8 hours) every time I did such an upgrade.
One day I notice my blog was extremely slower then usual. I open the page source to take a look and found that there were a big chunk of links added to the bottom of every page. I figure the footer.php file has been temper. And yes indeed the footer.php was changed by someone else. It seems to me the only reason that can happen is that the hacker got my WordPress login or he got the ftp login to my site. So I changed both passwords. The hacker may get this login information through a security hole in version 2.12. So I was forced to do an upgrade to version 2.50. Again it took me many hours, more than 8 hours actually. But it all went well eventually and version 2.50 is great compare to 2.12. So it really worth it.
Here are the steps I took to do the upgrade.
- Download a copy of existing files. Backup database and download the backup
- Deactivate all plugins
- Delete all existing WordPress files
- Upload a copy of version 2.50
- Modify wp-config.php and put in the correct database information. Put in a random secrete key also. That was new security feature in version 2.50 to make cookie harder to hack
- Open a browser to the upgrade page (wp-admin/upgrade.php) and follow the instruction
- From the backup files downloaded earlier copy the content/theme folder for the theme used and the content/uploads folder to the production site
- Login to Wordpress. Select the theme used and reactivate all plugins used
- Login to WordPress. Click on the settings link on the upper right hand corner and then click on the Miscellaneous link. Update the uploads folder path to “wp-content/uploads”
- Go over each of the plugins used and upgrade them if they have a new version
- Review CGI error log and make sure there is no CGI error. If there is then most likely a plugin is not compatible with version 2.50. Find it out and upgrade it.
It doesn’t seem very complicated. But it took me for a long while to find out why file upload didn’t work because I didn’t set the uploads folder path correctly. By the way file upload only works well in Firefox. It doesn’t work in IE. I just don’t want to waste time to figure out why.
Also It took me a long time to go over the plugins I used and upgrade them to the most recent version. Since I didn’t upgrade WordPress for a while most the plugin I used have new version come out.
But again it all went well and I am happy with it.


[…] my previous blog income report I mentioned that my blog traffic was down observably after I upgrade WordPress to 2.50. I believe I found what was going on. I believe it have to do with the new configuration settings […]