Sorry about this seemingly basic question, but I have looked at the similar questions and those solutions (including Bluehost documentation) hasn’t worked for me.
I have a Bluehost account hosting multiple add-on domains. Currently:
- a.com > Existing wordpress site, located at
public_html/a
- b.com > Points to an empty directory at
public_html/b
All I want to do is change my wordpress site from a.com
to b.com
.
I have read answers here, as well as other posts online, that suggest adding:
define('WP_HOME','http://b.com');
define('WP_SITEURL','http://b.com');
But of course that doesn’t work. I don’t see how that would work either since when I enter b.com, the server would be looking under folder b/ which is empty. I figure I’m just missing a simple step somewhere.
2
Answers
So this seems to be working for me so far:
b.com
public_html/b
and renamepublic_html/a
topublic_html/b
Did you check this tutorial?
https://www.wpbeginner.com/wp-tutorials/how-to-change-your-wordpress-site-urls-step-by-step/
Also what I would suggest is to use something like the Better Search Replace plugin https://wordpress.org/plugins/better-search-replace/ to scan your database and remove all references to domain "a.com" and replace it with "b.com"