0

I have just built a wordpress website and now my partner has advised me that she has bought a different domain name and wants me to swap it for the current one.

She has purchased the new domain from the same company she has hosting with for the current site.

There support team said the easiest way would be for me to forward the new domain name so that it is pointing at the current site.

However this will not change the url's right? So my site will still show the old domain name in the url?

What's the best way around this issue?

I don't really want to setup a new hosting package under the new domain name and have to migrate the site across.

2 Answers 2

2

The proper way is after pointing the new domain to your hosting account to change the URL references in the Database. So, besides the siteurl & home options you shouldn't forget upload path at the same table and a complete search & replace for local links and media URLs inside post contents.

There are many ways to do this according to the Codex.

Lately I've been using the Wordpress Search & Replace tool that can scan all required tables to replace the URLs. ( Always backup the DB first )

0

The easiest way to handle this issue is to go throw the next steps:

  1. Dump your database
  2. Open dump and replace old domain with new domain
  3. Import your dump
3
  • 1
    That would break serialized values. Not a good idea.
    – fuxia
    Apr 14, 2013 at 9:16
  • Never faced up with such kind of problem. What values are stored serialized? Apr 14, 2013 at 9:53
  • dashboard_widget_options and some transients. Plus, maybe some plugin option. Not that important but worth to be mentioned.
    – fuxia
    Apr 14, 2013 at 10:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.