CGI: Output - Location
If the value is a full URL,
the server returns a "redirect" to the
client to retrieve the specified object directly.
Location: http://WWW.Stars.com/
If you want to reference another file on your own server, you
should output a partial URL, as shown here:
#! /usr/bin/perl
$home = "/home/web/public_html/Software/Perl";
require "$home/cgi-lib.pl"; # CGI library
&ReadParse; # Get form data set
$button = $in{'Button'}; # Which button ?
$button =~ s/Locate/Location/;
$button =~ s/Resources/References/;
# Redirect server.
print "Location: /$button\n\n";
|
|