How to get the URL?

Discussion in 'Javascript' started by ASK, Feb 15, 2004.

  1. ASK

    ASK Guest

    Hi,

    I am new to Javascript.
    I have registered 3 domain names (www.web-1.com , www.web-2.com and
    www.web-3.com and all the 3 domain names points to same hosted
    website. When someone browses my website using the URL
    http://www.web-2.com then I want a welcome message as "Welcome to
    web-2.com", when someone browses my website using the URL
    http://www.web-3.com then I want a welcome message as "Welcome to
    web-3.com".

    How can I achive this because I will have to dynamically change the
    welcome message? I am not interested in maintaining multiple pages.
    Any solution?


    ASK.
     
    ASK, Feb 15, 2004
    #1
    1. Advertising

  2. On 15 Feb 2004 08:46:33 -0800, ASK <> wrote:

    [snip]

    > How can I achive this because I will have to dynamically change the
    > welcome message? I am not interested in maintaining multiple pages.
    > Any solution?


    It would be best to do this server-side. However, window.location.href (or
    just window.location) will retreive what you want.

    Mike

    --
    Michael Winter
    d (replace ".invalid" with ".uk" to reply)
     
    Michael Winter, Feb 15, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Doug
    Replies:
    0
    Views:
    518
  2. Jon paugh
    Replies:
    1
    Views:
    883
  3. wl
    Replies:
    1
    Views:
    4,463
  4. Just D.
    Replies:
    0
    Views:
    510
    Just D.
    Aug 11, 2004
  5. David Thielen

    Get full url from relative url

    David Thielen, May 25, 2006, in forum: ASP .Net Web Controls
    Replies:
    2
    Views:
    219
    David Thielen
    May 26, 2006
Loading...

Share This Page