To transfer Drupal to WordPress a series of MySQL queries must be run to read Drupal database content and change it to WordPress. Writing temporary tables on its database makes some changes to the Drupal content. However, it is important to backup Drupal database information before doing a WordPress migration. Adjust the settings after the migration to allow the WordPress installation to start.
This tutorial will guide you on how to change your website utilizing FTP.
Using File Transfer Protocol (FTP), you can move most of the websites files. The first step of this guide will reveal how to use FTP to move these files. Some websites are compound. They are database driven with MySQL Databases.
The second stage of the guide, demonstrates how to migrate a database and configure file updates, especially if you are an advanced user.
Let us begin the basic website migration steps:
Step 1 – Prepare
Gather all necessary information needed before starting the website move. The following will be required for the migration.
- A FTP program
- Login details for both new and existing hosts
- Access to all the files
You also need to develop a plan for which site needs to be moved and to where. This would help you check details as you proceed.
Step 2 – Website Files Downloading
- Open the FTP application
- Using the FTP user you possess, connect to your hosting
- Check the folders and files on the right hand side
- Enter the public html folder if not already there
- Ensure you can see all your website files
- Select each item in the right hand window
- Download the files
Step 3 – Exporting the MySQL Database
Note all websites use MySQL or databases. If the website doesn’t use SQL, go to “Website Files uploading”. You need PHPMyAdmin access to generate the export. You can get the connection information in the configuration files of the site.
- Log into PHPMyAdmin
- Click the databases your WordPress utilizes on the left side
- Click ‘Export’ at the top, and select all
- Download the SQL file by Clicking ‘go’ on the export page
With the database and the website files, the next stage is to upload them to your hosting.
Step 4 – Website Files uploading
- Connect to the hosting account using The FTP application
- Go through the public html folder
- Drag the website files from the left area into the public html directory on the right
- Upload all the files
While files are uploading, import the SQL database.
Step 5 – Importing the MySQL Database
You will be required to generate a new database for WordPress to use.
- Log into the control panel
- Click on ‘MySQL Database Wizard’
- Fill in all the information. Ensure you note down what you fill
- Tick ‘select all’ on the next page. When you are asked the permissions the user should have
- The database should have been created by now
Import the database you have created via these steps.
- Click PHPMyAdmin in the control panel
- Click on the created database
- Click the ‘Import’ button at the top
- Locate the export you made from the preceding host by clicking on the choose file button
- Click ‘Go’
Step 6 – Update any configuration Files
In this final stage, update any configuration files if your site has such files, especially if your site utilizes SQL.
- Go through the folder that has WordPress using The FTP application
- Locate the configuration file. If uncertain of its location, Google the script name and ‘Config File’ to find exactly where it is
- Right click on the file and select ‘Edit’
- Open the file using you default text editor
- Look for database settings section
- Edit every setting with the details for the database created
Note that they may not always be named as follows:
DB_NAME: The database name you chose
DB_USER: The database user-name you chose (Most of the time it can be similar to the database name)
DB_PASSWORD: Password
DB_HOST: The database host. For cPanel that will be a Localhost.
While creating the database, the host will display if you are on the cluster. With all the files moved, databases imported, and updated, preview the website.
You will have to edit a file called ‘Hosts’. The file may be located at:
- Windows C:\windows\system32\drivers\etc\hosts
- Mac/private/etc/hosts
- Linux /etc/hosts.
- Open the file using your text editor. Right click on the Notepad text editor and click on ‘run as administrator’.
- Add the line IP www.yourdomain.com yourdomain.com
- Substitute ‘yourdomain.com’ with your real domain name and IP with the IP of the server. To locate find the IP of the server, ping the URL or check on the control panel for the ‘shared IP’.
- Once all these changes have occurred, save the file and restart your computer
- Once your computer restarts, browse to your website as usual
- Remove the line from your hosts file to allow you to view the site on your existing host.
- If your website loads rightly and you are completely assure it has no hitches, you can you can update your name servers if you have not yet done so.
This will make the end of a successful transfer from Drupal to WordPress.