Moving the site among directories/sub-directories

From Joomla! Documentation

Revision as of 11:43, 22 February 2010 by Mandville (talk | contribs) (added cats)
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Many times you install Joomla in a sub-directory and then want to move it to a higher level directory, here's a short tutorial on how to do it. Note that this is written for Joomla 1.5, in case you are still using Joomla 1.0, migrate now!

Say you have installed Joomla in the following folder public_html/tryjoomla Now that you are satisfied with the site, you'll want to move to public_html

1. Move all the files from the sub-directory to the upper level directory, you can use your favourite FTP client or the panel that your hosting service provides to do this.

2. Download and open the configuration.php file in a text editor.

3. Look for the following variables

var $log_path
var $tmp_path
var $ftp_root
var $live_site

The first two will definitely have a long value, the other two might not. The first line will most probably look something similar to

var $log_path = '/home/username/public_html/tryjoomla/logs';

You need to change this to

var $log_path = '/home/username/public_html/logs';

We've simply removed the tryjoomla folder name from the path. Similarly change the tmp path

var $tmp_path = '/home/username/public_html/tmp';

If you have the $live_site and $ftp_root variables with some values, they too need to give up the tryjoomla folder, so they can look something like

var $live_site = 'http://www.yoursite.com/tryjoomla';

becomes

var $live_site = 'http://www.yoursite.com';

AND

var $ftp_root = 'public_html/tryjoomla';

becomes

var $ftp_root = 'public_html';

If you have cache enabled, you will need to login to the administrator (Which will now be at http://www.yoursite.com/administrator and not http://www.yoursite.com/tryjoomla/administrator), and go to Tools -> Clean Cache and delete all cache files.