Changing Domain Name Failure (8 posts)

    Posted 2 years ago #

    Can someone help, please?

    I've just messed up my site which I've had "under construction" for a few months, but not yet launched. I thought I followed instructions from WP Forum and YouTube tutorials correctly for changing my domain name as follows:

    I did a database backup of my blog. Then logged into CPanel, then into phpMySQL. Went to my active child theme: twentytwelve. Only one file there: style.css. I added a new file: functions.php. Edited this empty file by typing in the following three lines (nothing else):
    /*Changing domain names in hard-wired fashion*/ update_option('siteurl','http://smartgridix.com');

    (Sudden thought: should I have enclosed those lines between


    At first, I commented out all of the three lines -- then I got brave, and changed to commenting out only the first text line describing the action (as above), presumably making active the two lines of 'update_option' commands. I saved this active file (as I had saved previously the fully commented inactive three lines).

    I went to Dashboard>Settings>General and changed my home and site URLs to smartgridix.com. I saved these changes.

    I then typed in the new URL, "smartgridix.com/wp-admin" to Mozilla browser and the following error message came up:

    /* Changing domain names in hard-wired fashion update_option('siteurl','http://smartgridix.com'); update_option('home','http://smartgridix.com');*/
    Warning: Cannot modify header information - headers already sent by (output started at /home/dompeter/public_html/wp-content/themes/MyTwentyTwelveChild/functions.php:9) in /home/dompeter/public_html/wp-includes/pluggable.php on line 876

    Panicking (this happens easily when making coding changes, at least to me), I uploaded/restored my saved database files using my C-Panel, but still get the same error message above.

    I'd really appreciate a helping hand, as I am now stuck and cannot access my web site. I spent two days reading and watching how-to YouTube videos on how to do this domain name change, and I still screwed up!

    My only other option is to recreate the web-site/blog from scratch with a fresh copy of WP and with the new URLs but it seems to me that that should not be necessary.....

    Many thanks and sorry for longish message.

  2. kmessinger
    Forum Moderator
    Posted 2 years ago #

    At smartgridix.com/wp-admin I get a holding page like the domain name is not yet setup.


    Posted 2 years ago #

    Thank you. Also, the codex file you sent is helpful re the section on hard-wiring the new domain names: "Edit wp-config.php".

    I am going to try that. Don't really want the domain name to be hard-wired, but if it works, then I'll go with it because the other approaches are so tricky (and I am a "detail" type of guy).

    I was able to get my site up again with the old domain name. FYI, I have the site cloaked since it is still messy/draft-ey, using "Ultimate Coming Soon" plug-in.

    Posted 2 years ago #

    However, I've discovered that I can visit my previous domain name at my site and my WP blog shows up perfectly, but when I add on the wp-admin extension to it in order to access my dashboard and press enter, it then points me to the new domain: smartgridix.com, but with a meaningless front page, and with the following URL in the URL box:


    I'm not sure how to read this, but it seems that the new domain name, smartgridix.com, is not connected to my wordpress dashboard/admin login?

    Posted 2 years ago #

    I still can't get into my old site or the same site with the new domain name. Breaking the problem down into digestible pieces:

    1. I added this code to my WP-config file below the top line which is: <?php

    2. I added this code into my twentytwelve theme/functions.php file, again below the first <?php :

    3. I added this code into my twentytwelve child theme/functions.php file (I had to create a functions.php file first and this is the only entry) :
    4. In my dashboard (Settings>General) of my original site, I changed the Home and Site URLs from the old URLs to the new URLs

    Now, when I browse to my old domain, the old site comes up for about 1 second and then it goes to a new site that says in its header smartgridix.com in its header, but has misc. stuff on the rest of the page. When I browse to my new site name, I also get this nonsense site, but I do not get the "skipping" through the old site front page first like I do above.

    Any and all help appreciated.

  6. kmessinger
    Forum Moderator
    Posted 2 years ago #

    Your domain is at Hostgator. You should contact them about the 500 error. It can take a while, 24-48 hours, for a site to propagate thru the web but yours should have by now.

    Registered through: GoDaddy.com, LLC (http://www.godaddy.com)
    Domain Name: SMARTGRIDIX.COM
    Created on: 24-Jan-13
    Expires on: 24-Jan-14
    Last Updated on: 26-Jan-13
    Domain servers in listed order:

  7. kmessinger
    Forum Moderator
    Posted 2 years ago #

    There should be a file manager here where you can confirm your install of wordpress. http://smartgridix.com:2082/?locale=en

    Posted 2 years ago #

    Thank u. That is helpful. I will follow up on your suggestions

Topic Closed

This topic has been closed to new replies.

About this Topic