Re: One web server, multiple domains



On October 28, 2008 03:23, in comp.os.linux.networking, sb5309@xxxxxxxxx
(sb5309@xxxxxxxxx) wrote:

A web server typically hosts multiple domains, eg "abcd.com",
"123456.com" etc.

When I ping "abcd.com" or "123456.com", it returns a single IP
address.

What mechanism is used to identify which domain to serve ?

Domain identification is a part of the HTTP protocol that the client
application (the web browser) populates.

When the client (web browser) "clicks" on a hyperlink, the browser will
disect the hyperlink to determine the name of the server. For instance, if
the hyperlink were http://www.yahoo.com/index.html, then the brower would
first determine that the server to contact is www.yahoo.com.

The client then opens a communications path to that server, and asks for the
web page using the entire name from the url. In my yahoo example, the
browser would connect to TCP port 80 of www.yahoo.com and ask for the
www.yahoo.com/index.html webpage.

Now, there may be more than one domain name that points to the machine that
www.yahoo.com points to. So, the web server on that machine looks at the
text of the request ("GET www.yahoo.com/index.html") and determines that it
has to retrieve the "index.html" page from the "www.yahoo.com" profile.

That's it. It's done by the web server, in response to details sent by the
web browser.

--
Lew Pitcher

Master Codewright & JOAT-in-training | Registered Linux User #112576
http://pitcher.digitalfreehold.ca/ | GPG public key available by request
---------- Slackware - Because I know what I'm doing. ------


.



Relevant Pages

  • Re: hyperlink function in a normal button
    ... on server side click handler. ... but in this case client has no information on transfer and if the client ... > I understand that i can use the hyperlink button for this but in this case ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Installing a JRE plug-in
    ... You are correct that the JSP server runs Java. ... Sorry for not being explicit about client versus server. ... referring to plugins in a client side web browser. ...
    (Debian-User)
  • Re: One web server, multiple domains
    ... When the client (web browser) "clicks" on a hyperlink, ... first determine that the server to contact is www.yahoo.com. ...
    (comp.os.linux.networking)
  • Re: file open with web app
    ... this is likely the Windows Forms dialog. ... You have nothing out of the box for this as accessing client side files from ... a server would be a security issue so HTML has only something that allows ... hyperlink I have the target set to _blank. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Installing a JRE plug-in
    ... You are correct that the JSP server runs Java. ... Sorry for not being explicit about client versus server. ... referring to plugins in a client side web browser. ...
    (Debian-User)