Have your die statement print a message. In IIS 5 the current working directory is NOT the script directory but the root of the web. Let's say your main script and tester.pl are in cgi-bin, as in
http://webserver/cgi-bin/main.pl your open statement should be open(inf, "cgi-bin/tester.pl") or die $!; I'm guessing the script is die'ing because it can't find the file. Die $! Will tell you what the problem is. -----Original Message----- From: Mike Kalinovich [mailto:mike.kalinovich@;inquent.com] Sent: Thursday, October 17, 2002 19:10 PM To: Perl-Win32-Users Subject: CGI on iis5 question Importance: Low Hello, Very simple script, opens a file, reads it into an array, and then it "should" display it to the browser. But it's not, and I'm at a loss why. It works command line fine. But not via the web. Using ActiveState build 633 (perl -v = v5.6.1) IIS5 entries are: .cgi d:\perl\bin\perl.exe %s %s .pl d:\perl\bin\perl.exe %s %s What am I missing ? No errors are reported via the web. Any tips would be good. Mike Kalinovich ******* insert code ******* #!/usr/bin/perl print "Content-type:text/html\n\n"; open(inf,"tester.pl") or die; @ary = <inf>; print "file is opened and dumped into array\n"; foreach $line (@ary) { chomp $line; print "$line\n"; } close(inf) _______________________________________________ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs _______________________________________________ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs