Results 1 to 2 of 2

Thread: One Website with TWO names?

  1. #1
    Join Date
    Feb 2006
    Posts
    68
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default One Website with TWO names?

    I was just wondering is something like this would be possible

    I have two domain names I currently am not using. Eventually I will do something with them.

    I'll call them XYZ.com and ABC.com


    If I have a website with facts that have nothing to do with either name I know I can redirect the urls very easily to the index.html

    I was wondering if it would be possible to just to have some kind of script on the page so if the user went to http://xyz.com you'd get the page but the logo, the title bar and the <h1> title would say "Welcome to XYZ.com".

    BUT If the user typed in http://abc.com the exact same page would appear but with the logo, title bar and header "Welcome to ABC.Com"

    Since neither url has anything to do with the webpage contents rather than make and copy the pages twice, would it be possible through some coding, I'm guessing Javascript to do this.

    I don't know really WHY I'd want to do this, I was just wondering in.

    I know it can be done but I wasn't looking for anything overly complex.

    Thanks

  2. #2
    Join Date
    Apr 2008
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default 1 site 2 names w/ different header

    I do that, I essentially do it in PHP I check the name of the server that was invoked, and depending on what that is, I serve a different header.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •