programming-examples/perl/CGI/Viewing Environment Variables in a CGI Script.pl

15 lines
231 B
Perl
Raw Normal View History

2019-11-15 12:59:38 +01:00
#!/usr/bin/perl -T
use strict;
use CGI qw/:standard/;
print header,
start_html('Environment Variables');
foreach my $variable (keys %ENV) {
print p("$variable is $ENV{$variable}");
}
print end_html;
exit;