How to Break Your WordPress Site with GoDaddy

You may notice that the URL you’re seeing at the top of the page is not agalsoftware.com, but joelagalsoff.com. Or maybe I’ve already fixed the problem by the time you read this. Either way, I broke my domain and then my WordPress installation.

First thing’s first. After registering a couple more domain names for some website ideas, I decided that I wanted to host all of my sites from subdirectories. I decided to make another domain to resolve to the root directory of my site and then make agalsoftware.com point to the /blog folder, where it was already installed.

I changed my hosting account’s primary domain to joelagalsoff.com and then went about preparing WordPress to use the new directory structure. Since agalsoftware.com would now point to /blog, I changed my WordPress address to http://agalsoftware.com and the blog URL to http://agalsoftware.com and clicked save.

That’s when things went south. WordPress would not resolve correctly because agalsoftware.com still pointed to /, but the blog was in /blog. At first I just got an oddly formatted version of my site. A little while later, agalsoftware.com went to a 404 page because agalsoftware.com was no longer associated with a GoDaddy hosted server. By this time, joelagalsoff.com was resolving to the root directory. However, all of my WordPress resources expected agalsoftware.com, not joelagalsoff.com. I couldn’t even access the admin pages.

Luckily, I found this article from WordPress about changing your site’s domain. I added:

update_option('siteurl','http://joelagalsoff.com');
update_option('home','http://joelagalsoff.com/blog');

to my theme’s functions.php file and refreshed my page a couple of times until everything looked normal. Then I removed the lines and everything was still working.

I can’t add agalsoftware.com back to the list of domains hosted on my server because the primary domain change hasn’t gone through yet. If you keep getting:

Domain name is used. Please select a new domain name.

when you try to add back your old domain, you’ll have to keep waiting until the changes get made. I called GoDaddy support and they said it could take up to 24 hours for the change to go through. I’ll post an update if anything interesting happens.

Edit: Okay the domain change went through. Now I’m unforwarding agalsoftware.com so it resolves normally. We’ll see what happens when I try to put WordPress back together…

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>