WordPress.org

Ready to get started?Download WordPress

Forums

How do I keep a Parked Domain Name in the address line of a browser (3 posts)

  1. CharlesSeymourJr
    Member
    Posted 5 years ago #

    Here's my problem: I have parked LizSeymour.com on top of StageMagazineOnline.com (which already has 6 versions of WP in various subdirectories). I pointed LizSeymour.com to /sings in my control panel and WP opens right away when that Domain Name is used.

    However...

    When using any link within WP, the domain name switches to StageMagazineOnline.com (as you can see).

    I followed poppacket's suggestion and added this to my wp-config.php file:

    $hostname = $_SERVER['SERVER_NAME'];
    $hostname = str_replace('www.', '', $hostname);
    if ($hostname == 'lizseymour.com') {
    define('WP_SITEURL', 'http://lizseymour.com');
    define('WP_HOME', 'http://lizseymour.com');
    }

    Unfortunately, when moving around WP, the name changes back to StageMagazineOnline.com/(and then the file names being used)

    What am I missing?
    How can this best be done?
    Also... I will be adding MORE WP blogs to this main address, so it's very important to keep the new Domain Name when people visit my various sites.

    Thanks for your help.

    Charlie

    [Apologies to Poppacket for contacting him outside of this forum... I had trouble finding out how to add a new thread - it's not listed on most of the pages.]

  2. Storyman
    Member
    Posted 5 years ago #

    Have you tried a mod-rewrite in .htaccess?

  3. CharlesSeymourJr
    Member
    Posted 5 years ago #

    Whoops... my bad. It was MUCH simpler than I thought.

    I had put the address of the blog in as StageMagazineOnline.com before I had the Domain Name registered. Now that the Domain Name points to the correct subdirectory AND I've changed the address of the site to show LizSeymour.com, it works.

    No extra coding was needed.

    OY... it's all in the details!

    Thanks.

Topic Closed

This topic has been closed to new replies.

About this Topic