0

I have an old WordPress site that I am redeveloping. I'm redeveloping it on what will become the new host for the site. The idea is that when the new site is ready I will change the DNS records on my domain and point it to the new site. I'm using a temporary domain, http://sergedenim.es for the development site. http://sergedenimes.com is the live site and the domain I want to use as the primary.

Now I reckon this would usually be quite an easy affair to achieve:

  • change the DNS of the temporary domain to point away from new site.
  • change the DNS record of the main domain to point to the new site.
  • go to phpMyAdmin and edit the "site url" and "wordpress url" to be the new domain

The trouble is that my new host (Gandi.net) uses vhosts and instances for it's hosting over the traditional cpanel shared hosting. Is there any way to achieve what I want to on this type of hosting setup. I don't have a great understanding of how vhosts works but I think it allows one to have multiple websites on different domains on one hosting account (not that i require this). I just want one website and for its domain name to change.

1 Answer 1

0

You can set the domain for the WP install in the config-file wp-config.php and so its easy to set an new domain for a install.

define('WP_SITEURL', 'http://www.example.com');
define('WP_HOME', 'http://www.example.com/blog');

Now use WordPress this domains and the settings in backend was not deciding.

But the task after this small change is, that you change the url to the new domain in the database, like for attachments or images. She are inside the tables, with completly link. You can use the plugin Search & Replace or you change directly in the database via a db-tool, like Adminer or phpMyAdmin.

Your Answer

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

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