Best practices to move WP another domain within same Dreamhost account

wordpress

#1

I help run our school’s PTA website. We’re a non-profit and our new board would like to use the .org domain we had registered along side .net and .com domains names of our site when we originally setup our website seven years ago. Currently we just have a forwarding in place via the DreamHost so if you went to domain.org you end-up on domain.com right now. All the domains are in our DreamHost account so I’m thinking (and could be totally wrong about this) but can’t I just do the following to make the switch? Or should I do an export/import?

  1. Remove the .org to .com forwarding.
  2. Change the domain info within wordpress
  3. Change the directry info for the .org root to point to the where the .com site is now?
  4. Update the .htaccess file on the .com site to redirect to the .org pages? 301 redirects?

That’s all I got a the moment.


#2

For step 3 I’d rename the directory to make the magic happen, with that method there is no confusion down the road. Your method of repointing via the panel also works, but 5 years later someone could end up pulling there hair going “wtf why did they do that”…or worse, “I can’t figure out why it works this way.” To rename the directories what you would actually want to do is make the .org a “fully hosted” domain using the same USER as the .com. When you do that the dreamhost panel will add a directory for the .org… once it has been created you would:

mv example.com TEMP 
mv example.org example.com
mv TEMP example.org

With Wordpress there will also be additional database updates needed. Wordpress stores full absolute links (i.e including the domain name) in the database. Two methods are use phpmyadmin to manually update, or there is also a Wordpress plugin that can be used.