I have a CGI script running on a UNIX box. I need it to be able to access Environment variables (set in the .profile of the user apache runs as). I can do this command line by: my $testvariable = $ENV{TESTVAR}. This works command line, I can see this when I print it, however I would like to know how to achieve the same thing via CGI, when I run the script as a CGI page the $testvariable is empty.