> David>         That would be IE and AOL and WebTV browsers. None of them send
> David> HTTP_REFERER headers in the requests. I managed to get around it by
>        ^^^^^^^^^^^^

> not HTTP_REFERER.

        The header passed to the server is, in fact, HTTP_REFRERER. Here's
an example of the entire environment requested in a GET from a local page on
http://localhost/index.pl on my laptop.

<!--
DOCUMENT_ROOT is: /usr/local/apache/htdocs
GATEWAY_INTERFACE is: CGI/1.1
HTTP_ACCEPT is: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
image/png, */*
HTTP_ACCEPT_CHARSET is: iso-8859-1,*,utf-8
HTTP_ACCEPT_ENCODING is: gzip
HTTP_ACCEPT_LANGUAGE is: en
HTTP_CONNECTION is: Keep-Alive
HTTP_HOST is: localhost
HTTP_REFERER is: http://localhost/
HTTP_USER_AGENT is: Mozilla/4.77 [en] (X11; U; Linux 2.4.13-pre5-preemptive
i686)
PATH is: /usr/local/bin:/usr/bin:/bin:/usr/local/palm/bin:/usr/local/mysql/bin
QUERY_STRING is: section=linux
REMOTE_ADDR is: 127.0.0.1
REMOTE_PORT is: 35798
REQUEST_METHOD is: GET
REQUEST_URI is: /index.pl?section=linux
SCRIPT_FILENAME is: /usr/local/apache/htdocs/index.pl
SCRIPT_NAME is: /index.pl
SERVER_ADDR is: 127.0.0.1
SERVER_ADMIN is: [EMAIL PROTECTED]
SERVER_NAME is: localhost
SERVER_PORT is: 80
SERVER_PROTOCOL is: HTTP/1.0
SERVER_SIGNATURE is: <ADDRESS>Apache/1.3.19 Server at localhost Port
80</ADDRESS>

SERVER_SOFTWARE is: Apache/1.3.19 (Unix) PHP/4.0.4pl1 mod_gzip/1.3.19.1a
mod_perl/1.25
-->

        In perl, you can get that by doing the following:

use Env;
use CGI qw(:all);

print "<!--\n";
foreach $parameter ( sort keys %ENV ) {
        print "$parameter is: $ENV{$parameter}\n";
}
print "-->\n";




/d


Reply via email to