[page_submenu alignment=”center” sticky=”true” bg_color=”#225277″ link_color=”#ffffff”][page_link link_url=”#Preparation” title=”Preparation” id=”1552574750576-0″ tab_id=”1552574750577-6″] [/page_link][page_link link_url=”#Migrate” title=”Migrate Files & Database” id=”1552574750670-2″ tab_id=”1552574750671-9″] [/page_link][page_link title=”Configure Plugins for Live Site” id=”1552574750705-3″ tab_id=”1552574750705-9″ link_url=”#ConfigurePlugins”][/page_link][page_link title=”Configure Plugins for Dev Site” id=”1552574750739-0″ tab_id=”1552574750740-0″ link_url=”#DEVConfigurePlugins”][/page_link][page_link title=”Run Better Search Replace” id=”1552574750770-1″ tab_id=”1552574750771-5″ link_url=”#SearchReplace”][/page_link][page_link title=”Back To All Guides” id=”1552574750800-0″ tab_id=”1552574750800-0″ link_url=”/how-to-guides”][/page_link][/page_submenu]

PREPARATION STEPS

[divider line_type=”No Line” custom_height=”20″]

***Make sure the domain for this install is registered via our main GoDaddy account.

  • If necessary, create a cPanel account for this domain in the appropriate Liquid Web hosting server. (See Website Hosting instructions for more info. If the DNS for the LIVE site is not currently pointing to the LiquidWeb hosting server, hold off on doing so until the migration has been completed and tested.)
  • Ensure SSL Certificate is active for the PRODUCTION site (sub)domain.
  • Uninstall and Delete Wordfence Security from the DEV (sub)domain.
  • Confirm the LIVE domain is in the corresponding Login reCAPTCHA list.
  • Backup WP files and database for dev site before migrating to live.

MIGRATE WP FILES & DATABASE

[divider line_type=”No Line” custom_height=”20″]
Upload WordPress Files
  • Follow the steps here to upload your DEV site files to the PRODUCTION site.
  • Verify that the files have been moved over and unzipped via SFTP for the PRODUCTION site.
  • Ensure the backup tar.gz file has been deleted.
Create Database
    • In the LiquidWeb server, click into the LIVE/PRODUCTION domain’s cPanel, select MySQL Database:
      • Create a new database. (Use the (sub)domain name – without the extension – to name the database.)
      • Create a new user – use the same name as the database. Generate a password for the user and save.
      • Add the new database credentials to Lastpass.
      • Add the user to the database by selecting each then clicking add.
      • Select All Privileges and then Save Changes
    • Navigate back to the cPanel and select phpMyAdmin:
      • In the left hand column, select the database just created. (Note: the database should be empty, there should be no tables yet)
      • Once selected, click Import from the options along the top.
      • Click the Choose File button, select the DEV site database and click Go.
      • The database will take a little time to upload, you will get an Upload Complete message on the screen when completed.
      • In the left sidebar, select the database, the tables just imported should be below the database.
      • From the tables, select the Options table.
      • Change the “siteurl” and the “home” fields to the new URL of the LIVE/PRODUCTION site by double clicking on each field. Click off each field to save.
Update the wp-config.php File
  • In the cPanel account for the LIVE/PRODUCTION site, navigate to the File Manager.
    • Navigate to the public_html folder of the LIVE/PRODUCTION site.
    • Locate the wp-config.php file in the public_html folder. Click once to highlight.
    • Click “Edit” in the top nav to pull up an editable version of the wp-config.php file.
    • (You’ll need to click edit again on the popup screen.)
    • Update the DB_NAME, DB_USER, and DB_PASSWORD in this file to match the database credentials that you saved to LastPass.
    • Click “Save Changes.”
Verify Live Site
  • If you are not ready to switch the domain over to the new site and therefore have not updated your DNS records, follow the steps below to mask the site’s IP address to your local machine.
    • Open your Terminal and type “sudo nano /etc/hosts”, hit Enter
    • Enter the password for your local machine, hit Enter
    • Navigate down below the last record
    • Type the IP address of the server where your LIVE/PRODUCTION site lives.
    • Space over and type the URL of your LIVE/PRODUCTION site.
    • Type Control + X
    • Type Y (to save changes)
    • Hit Enter
  • Navigate to your URL and verify the site is populating

CONFIGURE PLUGINS FOR LIVE SITE

[divider line_type=”No Line” custom_height=”20″]
WordPress Plugins
  • Ensure the following plugins are configured properly for the LIVE site (sub)domain:
    • Easy HTTPS Redirection
    • Login no Captcha Recaptcha
    • TypeKit (if applicable)
    • Woocommerce and any extensions
  • Activate and configure the following plugins for the LIVE site (sub)domain:
  • If you had a Google Map element included on your DEV site, ensure you add a Google Maps API Key to your LIVE site under Salient > General Settings > CSS/Script Related > Google Maps API Key field.
  • Ensure that the privacy policy is on all forms
Google Analytics
  • Log into the Unbridled gmail account and go to the Google Analytics admin dashboard.
    • If the site is for a new client, create an account. Otherwise, select the correct account in the dropdown section.
    • Create a New Property. Enter the domain name into the Website Name textbox. Under Website URL, change to https:// and enter the domain name in the text box. Leave industry as is and change the time zone to Mountain Time.
    • Click Get Tracking ID
    • Copy the whole Tracking ID
    • Add the Google Analytics tracking code to the Salient interface – General Settings > CSS/Script Related > Paste code into the Google Analytics text box.

CONFIGURE PLUGINS FOR DEV SITE

[divider line_type=”No Line” custom_height=”20″]
  • Reinstall and Activate Wordfence following these instructions.
  • If MainWP was deactivated, reactivate and update the site in MainWP:
    • In the MainWP settings, save changes and copy the new Security ID.
    • In the MainWP dashboard, navigate to the child site dashboard using the child sites list on the left.
    • Scroll down to connection status and click Sync Now. This should return an error message.
    • In the tabs along the top select Edit, scroll down to Unique Child Security ID and enter the Security ID copied from the MainWP settings page. Save the changes.
    • Select the Overview tab along the top and scroll back to the connection status section. Click Sync Now. This should now show the site as synced.

RUN BETTER SEARCH AND REPLACE ON LIVE SITE

[divider line_type=”No Line” custom_height=”20″]
  • Make sure the Better Search and Replace plugin is activated.
  • Under Tools, select Better Search and Replace:
    • Enter the DEV (sub)domain in the Search for text box. Note: do not include the https:// or any / or pages trailing the domain.
    • Enter the LIVE (sub)domain in the Replace with text box. Note: do not include the https:// or any / or pages trailing the domain.
    • Select all the tables in the Select tables area.
    • Check the box for Case-Sensitive.
    • Leave the box checked for a dry run.
    • Run Search/Replace.
    • Once the dry run has completed it’s search, make sure there were no oddities in the findings. Double check the domains to make sure there are no extra characters.
    • Scroll back to the bottom, uncheck the dry run box and Run Search/Replace.