Are we there Yet?

Transitioning from to was amazingly simple. is running on WordPress for the blog and Coppermine Photo Gallery (CPG) for the photo albums. Both use SQL databases to store the information, so the process involved was to export the databases, copy the website files to the new host, then recreate the databases.

Both WordPress and CPG use MySQL databases. I was able to use PHPAdmin tool at Netfirms to export the WordPress database and the CPG database into .SQL files (text). The SQL file contained the SQL commands to recreate the tables and then insert the data.

My hosting plan at only includes one database, so I decided to put both WordPress and CPG into the same database. Since the tables that WordPress and CPG use have different names, this will not be a problem. The only problem that this will cause is that I have to be careful about how I back them up or export them otherwise I’ll have both WordPress and CPG in the same export file. also uses PHPAdmin, so importing the WordPress and CPG tables was trivial. I did find two problems with the import process. First, there was something about the comments that was throwing it off. Comments start with a — (the font doesn’t show it properly, but that’s two dashes), so I deleted any line that started with –. Second, there were a few options on the CREATE statements that were causing problems. They were the “ENGINE=MyISAM” and “DEFAULT CHARSET=latin1”. I used search and replace to remove these from the files and they imported great. I did set the default sort order, so the “DEFAULT CHARSET” was not needed.

As part of the move, I wanted to change the folder structure a bit. Netfirms, by default, installed CPG into a folder called /Gallery/NFPicturePro/. I wanted to shorten that up a bit, so when I moved the files, I just created a new folder called /cpg/. I used search and replace to change the the .SQL files that I had exported from WordPress and CPG, so they referenced the correct folder.

I have been using EditPad from JGSoft to edit the .SQL files. There is a Pro version and free Lite version. I have found the Lite version to be more than adequate for my editing needs. You can have multiple files open and the search and replace is awesome. EditPadLite is on just about every machine I use.

Be Sociable, Share!

Leave a Reply

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