Things to note
When you change the input fields in Setting > General they will not change the urls in embedded content (ie. post_meta). This means that some internal links will redirect to the live site when clicked, only after the domain has fully propogated will the embedded urls work properly
If the location of the site has an SSL certificate installed then the new location will also need an SSL otherwise links will not work as expected.
Domain Name Propagation
To ensure the domain name servers have been pointed, and have propagated correctly:
- Rename index.php to _index.php
- Create an index.html file and add ‘Site maintenance in progress’ inside
- When the site has propagated simple change index.html to _index.html and _index.php to index.php
- Login to cPanel
- If you do not have permissions to do this ask your supervisor
- On the dashboard of cPanel add a new addon domain with the same domain as the live site
- Using the ‘MySQL Databases’ button create a new database and write down the details
- if required create a user or assign a current user to the database with full permissions
- Using Installatron Application Installer install WordPress
- Applications Browser > Content Management > WordPress
- Create a new instance
- Remove the optional directory parameter to ensure the installer installs WP to the correct root folder, not another level deeper
- Disallowing automatic updates is recommended to improve the end user experience and breaks in the website
- Ensure the email used here is the support email to avoid spamming the client
- Make sure to dig into advanced settings and use an existing database
- Create a new instance
- Applications Browser > Content Management > WordPress
- After Installatron finishes its setup process for WordPress, access PHPMyAdmin and click on the database we created in step 3
- Using the provided SQL dump file provided for the transfer import it to the database (ensuring first that you are on the correct DB)
- Reload the page and check the prefixes before the table name
- There are new tables drop all tables un-needed tables ie
- if the import created tables like ‘new_wp_users’ and ‘wp_users’ also exists the you can drop all tables with just the ‘wp_’ prefix keeping the ‘new_wp_’ prefixed tables
- If the prefixes do not read like ‘wp_’ you need to change the wp-config.php to match the prefix provided in the DB
- Go back to PHPMyAdmin and then inside of the database select the settings table and update the site url with a temporary url
- This url will be constructed like so
[sharedIP]~/[cPanelusername]/[addon domain name]
- This url will be constructed like so
- Login to WordPress admin using the url you created above followed by/wp-admin
- Go to Settings > General, then change both the ‘WordPress Address (URL) and Site Address (URL)’ to the url we created in step 7
- Change the admin email to support@372digital.com.au and save changes
- Reset the password so that previous developers don’t have access anymore
- Go to the home page and ensure the website is showing up using the default theme
- Upload the wpcontent folder and unzip into the wp-content folder
- Go to the admin panel under Appearance > Themes and select the correct theme
- If all is working you are ready to point the domain to our host
- Go to Settings > General, then change both the ‘WordPress Address (URL) and Site Address (URL)’ to the website domain.
- Login to domain name manager and change the domain’s DNS to point to the new server.
- Let the domain propagate for a few minutes
- Disconnect a mobile phone from the office wi-fi. Then use mobile data to visit the website in Incognito mode (Google Chrome) or Private mode (Safari).
- If you see the text you have entered in index.html appear, then the domain is pointing correctly to the new server.
- If using SSL, login again to the WordPress admin and change the ‘WordPress Address (URL) and Site Address (URL)’ to https://www.domain.name
- Login to cPanel and click on the ‘Redirects’ icon.
- In the dropdown options, make sure the following are selected ’Type: Permanent (301)’ and ‘https?://(www.)?: domain name’.
- Enter the url in the ‘Redirects to’ field as ‘https://www.domain.name’
- Under www. redirection: make sure the ‘Redirect with or without www.’ is selected.
- Click the Add button to finish