Re: $ENV{'HTTP_USER_AGENT'

2002-02-08 Thread Kliment Ognianov
Bernd Lach wrote: >Hi there, > >I have a problem in detecting any kind of environment >variables. > >I always get a premature script error , when I launch sth like >this. > > >#!C:/Perl/bin/perl.exe -w >use diagnostics; >use strict; > >use CGI; > >$browser = $ENV{'HTTP_USER_AGENT'}; > >if ($

Re: $ENV{'HTTP_USER_AGENT'

2002-02-08 Thread Jeff 'japhy' Pinyan
On , Bernd Lach said: >#!C:/Perl/bin/perl.exe -w >use diagnostics; >use strict; You're using strict and -w, good. >use CGI; > >$browser = $ENV{'HTTP_USER_AGENT'}; Oops. You didn't declare $browser. my $browser = $ENV{HTTP_USER_AGENT}; -- Jeff "japhy" Pinyan [EMAIL PROTECTED] ht

RE: $ENV{'HTTP_USER_AGENT'

2002-02-08 Thread Camilo Gonzalez
If you're trying to view your results in a browser, you need to generate HTTP headers. -Original Message- From: Bernd Lach [mailto:[EMAIL PROTECTED]] Sent: None To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: $ENV{'HTTP_USER_AGENT' Hi there, I have a problem in detecting any kind of