Stuck on domain mapping from a sub-domain to an add-on domain

I created a sub-domain and got it just the way I want it. Now, I have a pre-existing url that I switched the nameservers to a different add-on domain as directed by the hosting service.
My problem is, everything is still on the sub-domain section, so I redirected the add-on to point to the sub-domain.
I need to somehow get the sub-domain files to show as the main site and url.
I know I probably way over-thought this, but FTP isn't an option. Help?

  • aecnu
    • WP Unicorn

    Greetings JenA,

    I thought it would be fairly simple.

    In all candidness, you would not believe how many people say those exact words for the not so very simple at all.

    What you are really trying to do from what I gather is domain masking or cloaking, cloaking the real domain name or in this case sub domain name.

    So lets get down to business here on getting this resolved.

    What is the sub domain of the first site - the real site name?

    What is the domain name you want to be actually used?

    What is the control panel of your hosting?

    Please advise.

    Cheers, Joe

  • JenA
    • WPMU DEV Initiate

    Thanks Joe. It's for a local charity that I offered to host free, so things didn't progress exactly as I would have liked. Hence, the call for help!

    The original domain is: http://uuspringfieldvt.org
    The sub-domain it was built on is: http://springfielduu.ngo411.com/

    I use CPanel at GreenGeeks

    I pointed the nameservers to an add-on domain at ngo411.com
    Because it was mapped, I redirected that add-on to the sub-domain, so at least it shows up.

    I need everything to show up as just the original domain.

    Thanks for your assistance!

  • Shawn
    • The Crimson Coder

    @JenA, have you changed the WordPress Address and Site Address here?:
    http://uuspringfieldvt.org/wp-admin/options-general.php

    This would be the first step. If that works, and gets the domain to stay in the address bar for you (and it should) then the next step is to do a find/replace in the database to ensure that the new domain URL is the only URL. You should be able to do that with something like this (you may need to change the table prefix):

    UPDATE wp_posts SET post_content = ( REPLACE (post_content,'springfielduu.ngo411.com','uuspringfieldvt.org'));
    UPDATE wp_posts SET post_content_filtered = ( REPLACE (post_content_filtered,'springfielduu.ngo411.com','uuspringfieldvt.org'));
    UPDATE wp_posts SET post_excerpt = ( REPLACE (post_excerpt,'springfielduu.ngo411.com','uuspringfieldvt.org'));
    UPDATE wp_posts SET guid = replace(guid,'springfielduu.ngo411.com','uuspringfieldvt.org');
  • JenA
    • WPMU DEV Initiate

    hmmmm... well, wp is not installed on the uuspringfieldvt.org
    It's installed on the subdomain: springfielduu.ngo411.com

    Ugh. I definitely overextended myself on this one- it is so easy to do when it's a fresh build as an add-on domain.

    Any further advice? I really appreciate it. Thank you.

  • Shawn
    • The Crimson Coder

    Is uuspringfieldvt.org mapped to springfielduu.ngo411.com within your control panel? If so, then it doesn't matter. Opening up uuspringfieldvt.org directly takes you to the right place, but this could just be a static redirect.

    If it's not mapped as a domain alias for your subdomain, then map it now (you may have to remove any forwarders currently configured).

  • aecnu
    • WP Unicorn

    Greetings JenA,

    I may have a simple solution of just using domain masking/cloaking.

    I have attached a file which is encrypted to lead to your sub site and maintain the URL.

    So if you setup these folks domain as a real domain and then put this file in the folder of that domain as index.htm or index.php it will redirect them to the subsite maintaining the Domain and original URL.

    Please advise if this does the job for you.

    Cheers, Joe

  • JenA
    • WPMU DEV Initiate

    I ended up just rebuilding the site the way I would have preferred to do it in the first place- thankfully it was a very simple site! Really tripped me up on that one.
    Just so you know, none of the suggestions above worked. Appreciate the effort.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.