httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From André Warnier ...@ice-sa.com>
Subject Re: [users@httpd] A question about the request line and the referer
Date Sat, 02 Aug 2008 19:52:37 GMT
Paul Li wrote:
> Yeh, I'm asking something about programming...
> 
> André. could you tell me why some referer pages are displayed as "-",
> but some are url ?

The "-" referer probably comes because the caller did not provide a 
"Referer:" header in his request.

For example, open a new browser and acces a URL on your server, then 
look at the access log.  It will probably show a "-" for the referer.

Or, if you have perl installed, re-do the example I sent earlier, but do 
not specify a "-H" switch.

Got it ?
The "referer" information in your access log *only* represents the 
content of the "Referer:" header sent by the client,  If there is none, 
then you get "-" for that field in the access log.
It is written so, so that if you have a program analysing your access 
log, it will not get confused because one line has fewer fields than the 
others.
Brilliant, those Apache developers, no ?

> 
> Thanks again and have a good weekend!
> 
And the same to you.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message