Support » Fixing WordPress » How do I keep a Parked Domain Name in the address line of a browser

  • CharlesSeymourJr


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


    When using any link within WP, the domain name switches to (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 == ‘’) {
    define(‘WP_SITEURL’, ‘’);
    define(‘WP_HOME’, ‘’);

    Unfortunately, when moving around WP, the name changes back to 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.


    [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.]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Storyman


    Have you tried a mod-rewrite in .htaccess?



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

    I had put the address of the blog in as 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, it works.

    No extra coding was needed.

    OY… it’s all in the details!


Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How do I keep a Parked Domain Name in the address line of a browser’ is closed to new replies.