Wednesday, 17 February 2010

How to transfer Joomla 1.5 from one host to another?

First you should know that your Joomla 1.5 consists of two components: Joomla files and Joomla database.

  • The files and folders of your Joomla application contain the scripts and core application code.

  • The Joomla database contains all records for your website such as your site sections, categories, articles, etc.


Let's assume that you are running your own *LAMP or *WAMP webserver or you have a hosting account with another company. You should know the root directory where your Joomla installation resides. It is often calledhttpdocspublic_html or www. Those are the so-called web server root directories. So let's suppose that your Joomla application in installed under your web server root directory.



The first thing you have to do when you want to transfer your Joomla applications to your SiteGround server, is to copy the entire content of your web server root directory straight into the public_html folder of your SiteGround hosting account.

If you are running your own server probably you have already had your Joomla site files on your hard drive. In case you are hosting your account on a remote machine, simply download your Joomla site files and directories (please mind that you should keep the directory structure in tact) on your desktop PC by using your favoriteFTP client. (You can find here how to backup your Joomla site.)

Once the download is finished, you should connect to your SiteGround FTP account, change your current working directory to the public_html one (this is the root/main folder for your website) and drag and drop your Joomla files and folders from your desktop PC to your public_html folder.

The next step you should follow is to create a full dump of your Joomla MySQL database. If you are running your own *WAMP or *LAMP server probbably you already have the phpMyadmin installed. If you are using different web hosting provider they should provide you with access to a database manipulation tool. You should ask them for further assistance. Here we assume that you are managing your databases with the phpMyadmin tool as it is the most popular tool for administrating MySQL databases.

Once you are logged in into your phpMyadmin tool, backing up (exporting) your database is simple. First choose your database from the left menu. Then click the Export tab. Select all the tables, check Add DROP TABLEand Save as file. Leave all other options untouched. Finally click on Go and the database dump will be downloaded to your PC. (You can find here how to export your database.)

We are done with your Joomla database backup and you should already have it downloaded on your hard drive. The next step we should take is to import your database dump to your SiteGround FTP account.

To do that, please, go to your cPanel area and create a brand new database with a name of your choice. Please mind that you can create databases only from your cPanel area. You cannot execute CREATE database; MySQL statement from the phpMyadmin tool. Once you've created your new database, please create a new database username and add it to the database you have created during the previous step. For detailed instructions on MySQL database creation please refer to the video tutorial for creating MySQL database and user in cPanel.

We assume that you have created your MySQL database and the next step is to go into your SiteGroundphpMyadmin interface.

To restore (import) a database in phpMyAdmin, first choose the database you'll be restoring from the left menu. Then click the Import tab. You have the option of importing a .sql file. Use the “Browse” button to find it on your PC and then click “Go” at the bottom.

If you receive an error message which says access denied, you should open the database dump file you have downloaded on your desktop PC with your favorite text editor and look for lines that may contain CREATE database db_name; and/or USE db_name; mysql statements. If you find any simply delete them and try to re-import the dump. If you run into troubles our friendly technical support team is available 24/7 and ready to help you.

The final step is to adjust the core settings which are defined in your main Joomla configuration.php file. Go to your SiteGround File Manager, change the current working directory to public_html and if you have followed the steps  mentioned above correctly you should be able to easily locate configuration.php file in there. Open it for editing.

Below are the main variables you need to adjust so they can fit to your new SiteGround hosting enviroment:
var $host = 'localhost'; // Leave it to localhost if you are unsure
var $user = 'your-database-user'; // This should be changed to yours
var $password = 'yourpass'; // Change it to the password for the database user
var $db = 'your-database-name'; // Change it to the name of your database

var $log_path = '/home/youruser/public_html/logs'; // This path varies for your webroot
var $tmp_path = '/home/youruser/public_html/tmp';

If you have correctly followed the instructions mentioned above and your domain name properly points to the DNS servers of your SiteGround hosting account you should be able to see your Joomla portal .

For more information, please visit our Joomla tutorial.

Note: This above instructions are for Joomla 1.5. In order to migrate a local Joomla 1.0 please follow these instructions.

No comments:

Post a Comment