View Single Post

  #1 (permalink)  
Old 08-11-2004
Chow
 
Posts: n/a
Default Server Name configuration???

Hello Gurus,

I have a question about my hostname setup for my webserver and
application server on my redhat 7.2 linux machine with Apache HTTPD
server 1.3 version.

I want to understand how actually browser resolves the hostname
part of the request url when a request is posted. For example we have
two url's,

One is absolute URL,

http://hostname/sampleuri/test.html

and other is relative URL,

/sampleuri/test.html

for say in a simple web page when we have two links to the above
two urls both resolve to

http://hostname/sampleuri/test.html ( assuming http://hostname is
where the request came from in the second case).

I want to know if we have to configure something in the system
properties in the OS like in /etc/hosts file or somewhere to do that.

I want to know how the browser actually get the hostname part of
the complete URL in the second case (Relative URL) and forms a
qualified URL to the resource. Please check the below url for my
question ( See the source of the file if you want to see the HTML
code)

http://www.geocities.com/cnadella/

http://geocities.com/cnadella/

Observe the second url's full path to see the difference for above
two request URLs.

I really don't if it is a system level configuration or a
webserver/application server level configuration. Please help me
understand this if anybody knows about it.

Thanks a lot in advance.


Cheer,

Nadella