Backstory:

Starting small in freelance is intimidating, because you may feel like you don’t have all the necessary skills, but a great learning experience!  Something I came across, once again, today.  I’d like to share my little tid bit of knowledge concerning subdomains.

Most sites I’ve worked with have already been live and they need some tweaks here and there.  Or the site isn’t advertised yet and the client wants to development under the domain they just bought.  But today was different.

Today, we are tackling transferring WordPress from my dev hosting to the client’s hosting.  But that wasn’t the complication.  The complication was that they had a domain that was already live for an existing site and the new site will not be under that same hosting.  So we don’t have a domain to test with.  And I also don’t have access to the account that created the domain, yet.

What I Tried:

  1. Built In Site Preview -> Blank page
  2. IP Address -> GoDaddy Under Construction Page
  3. IP/~username -> WordPress 404 page with no CSS

The Cause:

When setting up the account I had to put in a domain.  So I put the one we’d be transferring.  That obviously caused issues, as now the hosting is trying to connect with a domain that is not connected.  The preview would not work, wp-admin would not work.  Basically, stuck!

The Subdomain Solution:

Here’s the solution to that that didn’t occur to me naturally.  Set up a subdomain to be used temporarily.

First I just created one like usual, through cPanel -> Domains -> Subdomains.  But it only affected file structure.  I saw no way to change the IP address in which it will point to.  That is, until I explored a little bit and found the ‘Advanced DNS Zone Editor’.

There I found my subdomain pointing to my hosting IP address.  I could then edit it to the new IP address.

Less 24 hours later, everything is functioning just as it should and I can continue the migration to our new host, from my dev hosting, while the old site is still active with the domain we will transfer in the future.  Note it is possible to take up to 24 hours for the propagation period.