#!/usr/bin/perl -w use strict; # unbuffer STDOUT $| = 1; # get the name of this script my($thisscript) = __FILE__; $thisscript =~ s/^.*(?:\\|\/|\:)//; # string variable which will hold the %ENV data when we're done. my($ENVIRONMENT_DATA) = ''; # gather values for each available environment variable foreach (sort(keys(%ENV))) { $ENV{$_} ||= ' '; $ENVIRONMENT_DATA .= <<_env_ $_ $ENV{$_} _env_ } # print environment data and get outta' here print(<<__HTML__ ) and exit; Content-Type: text/html; charset=ISO-8859-1 CGI environment details
 
$ENVIRONMENT_DATA
 
see HTTP_REFERER
see PATH_INFO
see QUERY_STRING
 
__HTML__