Move Your Drupal Site to a New Location
This tutorial will show you how to move your Drupal site from one server to another. This example uses two live servers, however the same principles also apply for moving to or from a local server.
Your Drupal Site
I’m going to move a straight-forward Drupal install to a new location. Each Drupal site has two halves – the files and the database. We’re going to move one and then the other. Finally we’ll make sure they can talk to each other.
Download the Files to Your Desktop
Step 1 is to download all of your Drupal site’s files to your desktop.
Upload the Files to Your New Server
Step 2 is to upload them all your new server.
Export Your Old Database
For accesing the Drupal database I’m using phpMyAdmin which is commonly used by hosting companies and localhost setps. Find your site’s database and click on “Export”.
You’ll need to export your database as SQL. I’ve chosen to also compress it using Gzip so that the process is a little quicker. Finally click Go.
Import to the New Database
I’m also using phpMyAdmin at the new site. Click “Import”.
Choose the file that you just exported and click “Go” to import it into the new database.
Check to make sure that all the tables have imported sucessfully.
Change Settings.php
Finally we need to make sure that our files and database can talk to each other.
Login to your site’s files and go to /sites/default/ and open settings.php. There are two things you’ll need to change.
On line 92, chang the $db_url line to reflect the new database name, username and password.
On line 125, change $base_url to reflect the location of your new site.
That’s it. Visit your Drupal site in it’s new location and it should be live.
{loadposition drupalnewsletter}
I am confused about a few issues
1- how can i upload folders into my online host? i see in the drupal files to move there are folders
2-can u kindle write a clear example of how the modifications on line 92 and 125 will look like? my site name on local host is simply drupal
3-what about the .index page on my site? do i have to delete it or .php will just take over.
4-do i have to upload the drupal files in the folder where my other files are index files etc
Hi and welcome, asia!
Those are good questions! We would love to get into a discussion with you on this. If you are a student at [url=http://ostraining.com]ostraining.com[/url], please log into the support forum ([url=http://www.ostraining.com/support-forum/)]http://www.ostraining.com/s…[/url] and post the questions in there, so that one of our support techs can look into it for you. If you’re not a student, I hope you’ll consider becoming one, so that we can give you the attention you deserve. You can find out more about our online class at [url=http://www.ostraining.com/online]www.ostraining.com/online[/url]
Kind regards,
Nick
for transfer your localhost to godaddy, is different
the hostname is like yourdatabase.db.7774631.hostedresource. in yoyr db_url
see this help page: [url=http://support.godaddy.com/help/article/3440/what-is-the-url-for-the-database-publishing-service]http://support.godaddy.com/…[/url]
no changes for base_url
Can you still move your drupal site without the old database?