[Help] Creating a temporary URL for the developement of website on another server

akash80575

Regular Member
Joined
Jul 27, 2017
Messages
222
Reaction score
42
So I have a live website with Dreamhost but I am not happy with their services. I am on shared hosting and every next day they say I am out of my CPU Limits. Now I am planning to move my website to another host with 0 downtimes.

-What I have done?
1) Purchased Hosting
2) Moved all essential folders and database
3) Mapped the database exactly like my live website.

-What I need to do
1)
Want to create a temp URL to access my website and develop it further.
The temporary URL is redirecting me to my original website because of my database configuration. I need help.
 
What CMS? Wordpress or just PHP?

Why do you think it's due to your database?

Do you have the temporary URL pointed to the IP of the new server? I always set up a subdomain - like testing.mysite.com - and point it to the new server.
 
The easiest way to do it to get another server, set it up exactly like you have; and then go to your host file and make a new line and type:

123.123.124.12 yourdomain.com

Where the ip is the dev server ip and the domain is your current domain. Save it and exit.

If you open your site on the browser now, it will point to the new server, no matter what cms you have. To disable this, remove this entry.

Whoever wants to view your site has to do the same thing in their host file.



Btw, this method makes sure that your actual site continues to work fine. No dns change is needed.
 
Last edited:
If possible(allowed by first hosting) use duplicator wp plugin for migration to any other link , second method to replace url from the database
 
The easiest way to do it to get another server, set it up exactly like you have; and then go to your host file and make a new line and type:

123.123.124.12 yourdomain.com

Where the ip is the dev server ip and the domain is your current domain. Save it and exit.

If you open your site on the browser now, it will point to the new server, no matter what cms you have. To disable this, remove this entry.

Whoever wants to view your site has to do the same thing in their host file.



Btw, this method makes sure that your actual site continues to work fine. No dns change is needed.
Host file?
 
I am on Linux and blank on this.
 
Try
nano / etc / hosts

Remove spaces from the path. Bhw doesn't let me post it lol.
.pki
.wp-cli
wp-html

I am allowed for these three folders only
 
.pki
.wp-cli
wp-html

I am allowed for these three folders only
Don't do anything on the dev server. These changes are for your machine (or for the developer who will be developing your new site).


Changing the host file changes the domain to ip association locally. Get it?
 
Don't do anything on the dev server. These changes are for your machine (or for the developer who will be developing your new site).


Changing the host file changes the domain to ip association locally. Get it?
Yes
 
Back
Top