0

I have a live Wordpress site which is hosted on www.abc.com. I want to do some major changes on the website. So what I plan to do is, replicate the site to a separate domain www.xyz.com [by copying all the files and folders along with the database], make the changes in this test domain and then copy the changes to the original site.

But when I create the new domain, copy the files and create a new database, the new domain, www.xyz.com works fine. But all the urls on the site still points to www.abc.com. Eve when I try to go to admin panel, it redirects me to that of www.abc.com.

So, as you can see by migration is temporary, only for testing purpose, so I cannot just login to admin panel and change the domain there, as the site www.abc.com is still up and running. Please suggest a way out.

Anuj
  • 1,203
  • 3
  • 13
  • 20
  • some where the value for the domain is hard coded, find it, replace it. –  Sep 29 '13 at 00:11
  • Is there any standard file / path, where I can find it, without having to login as admin panel? – Anuj Sep 29 '13 at 00:19
  • Wordpress has not been written to support your use-case well. You need to buy specialized software and high-skilled (expensive) Wordpress support to get this done. It is not available as an easy answer to your straight forward question here. Also this is not the Wordpress support forums here, please contact the vendor of that software for your support options. – hakre Sep 29 '13 at 05:55
  • 3
    This question appears to be off-topic because it is about a support request with a third party software, here namely Wordpress. – hakre Sep 29 '13 at 05:55

3 Answers3

2

No, you have to edit the wp_options table in SQL. Change the rows with option_name containing "siteurl" and "home" to your new domain :)

shrty
  • 404
  • 3
  • 6
  • Well not for those settings, you can do with a constant in wp config. However in general Wordpress is not designed for domain migrations because it's just not a use-case wordpress developers have thought of and didn't design the software to support that. – hakre Sep 29 '13 at 05:53
1

Please suggest a way out.

The easiest is to change the domain name system on your test-box. That is you just put the website on your test-box and the domain stays, you just change the IP of the domain for this test-box only to that test-box. That done you do not need to change anything else and you can modify that website as you see fit. When done you just copy it over to the live-box back again.

All the other alternatives are a bit more complicated, if you want to do it differently, I suggest you to consult some more dedicated Q&A sites like Wordpress Stackexchange, the Wordpress Support Forums or the Wordpress Product Documentation.

Related Stackoverflow Q&A:

Community
  • 1
  • 1
hakre
  • 193,403
  • 52
  • 435
  • 836
0

Open config.php and edit website URI from there. Search for your old domain and change it with new one Good luck ;)

Zaur
  • 43
  • 1
  • 6