Most of you may have created your Joomla site in the localhost and you may be thinking of the way to move it to a live server on the web.
This also applies when you want to move the site from a one live server to another one.
The first thing you need to do is to upload the files to the new server. If your new web host give you a cPanel this is damn easy. (Free web hosts like x10hosting give you a cPanel for controlling your hosting account).
If you have the ability of extracting a compressed file in the server you can transfer your files very easy.
Note! Only *.zip, *.Gz, *.Bz2, or *.tar file types can be extracted in cPanel.
You can use either FTP or the online file manager of your hosting control panel to upload the files. When uploading files be careful to upload either to www folder or to a folder like public_html.
However if the new domain is mapped with a folder inside the public_html folder you need to upload the files there.
Eg: Main domain of my hosting account is sanjaya.me. So if i need to setup a site for sanjaya.me I would upload the files to public_html directly.
If I have created a sub domain jom.sanjaya.me which is mapped with the public_html/jom folder I must upload the files to that jom folder.
To upload the files via FTP you can use an FTP client like FileZilla.
(If you don’t have the ability of extracting a compressed file on the server this is the best way you can upload all your files.)
Here you can fill the ftp Host, ftp username and ftp password and connect to the server. You can enter into the correct server folder in the right side and drag and drop the files to it from the left panel which shows the files in your pc.
( You may get the FTP details when you create your hosting account for the first time. Or you may create additional FTP accounts through the page you get when you click FTP accounts button in the cpanel.)
Else you can use the online file manager. Below you see the file manager of cPanel.
Here you see an Upload button where you can upload the files one by one. (nearly impossible to upload thousands of files one by one, but you can upload a compressed file using this way as well as using ftp).
After uploading a compressed file you can extract the file by checking the checkbox for the compressed file and clicking on the extract button.
OK somehow you have now uploaded the files successfully.
Then what you have to do is to get a database prepared for the Joomla site.
First you need to get a database dump of your site.
Go to your localhost’s phpMyAdmin and select your database. Then press export.
Better you check the check boxes which I have marked in orange in the above picture. You may need that when you are importing a dump to a DB where you have data already.
You can press the GO button after selecting a file type.
Now you’ll get a backup of the database as a file.
What you have to do now is to create a database in your live server. In cPanel you can use MySql DataBase Wizard for this. There you can enter the name of the DB, a username and a password. And at last you’ll be asked about the permissions which you must give to the newly created DB user. You can check all the checkboxes there.
Now you have created a DB and a user for it.
Go to phpMyAdmin in your live server, select your database and go to the import tab. There you can see a browser button.
(You may see something like this :
Imported file compression will be automatically detected from: None, gzip, zip. So it means you can upload compressed formats too. Else you need to upload the .sql file directly.)
var $user = ‘root’;
var $db = ‘myoldDB’;
var $tmp_path = ‘E:\\Web\\xampp\\htdocs\\jom\\tmp’;
10 Comments
Sanjaya · November 6, 2010 at 12:56 pm
ooops got into so many probs when posting this. You may wonder I added the post directly editing the db 🙂
Sandun Madhawa · November 6, 2010 at 2:25 pm
There are very important facts in this article. Thanks Sanj.
My english knowledge is not enough to put a good comment….
well done. Keep it up. 🙂
Sanjaya · November 6, 2010 at 4:23 pm
Hey hey we don’t consider any language barriers you know,, Thanks for the comment 🙂
uthpala · November 6, 2010 at 2:48 pm
Thank you so much sanjaya,
virtuemart install karana widiya ganath article 1k danna puluwannam loku deyak.
Sanjaya · November 6, 2010 at 4:23 pm
install karanne nam anith components install karana widiatama thamai.
Methanin complete package eka download karaganna : http://virtuemart.net/downloads?task=view
Ita passe eka extract karala oke thyena com_virtuemart kiana eka samanya widiatama Joomla wala install karanna.
(Extensions>> Install/Uninstall)
Hebei virtuemart install karapu site ekak move karanawanam poddak configure karanna wenawa.
Sanjaya · November 7, 2010 at 1:16 am
You’ll need to set the file permissions of tmp folder to 777. And change the var $tmp_path in configuration file to the path of tmp folder in your new server ( You can do this in Site>>Global Configuration>>server in the Joomla backend).
Else you’ll get an error like this when installing an extension:
* JFolder::create: Path not in open_basedir paths * Warning! Failed to move file.
Check Help>>System Info >> Directory Permissions in the Joomla Backend to check whether you have set the correct permissions for certain folders.
uthpala · November 7, 2010 at 1:19 am
Thanks for all the guides,
Akila · November 7, 2010 at 9:11 am
Great work machn
keep it up
There are some hosting providers who support direct FTP file transfers between hosting spaces also.
And it would be a great help if you could post something about Language Translation too ;D
cheers
Sanjaya · November 7, 2010 at 9:24 am
Thanks a lot for your info machan.
There’s something like that in the cPanel too, isn’t it? But I have never got a successful result from that 🙁 And machan there’s a way where we can transfer whole cPanel. When transferring to a new host we can ask the new host to transfer the whole old cPanel which keeps all the settings unchanged, even the usernames and passwords.
By the way I have already written about Translations, see here:
http://blog.sanjaya.me/joomla-localization-post-in-english/
http://blog.sanjaya.me/how-to-localize-a-joomla-web-site/
Anil · November 7, 2010 at 12:22 pm
Niyamai macho,,
you are doing a great service by putting these kind of valuable articles.