can"t run perl script in /var/www/ directory

can"t run perl script in /var/www/ directory

am 19.11.2005 10:31:13 von bander8989

Hi

I tried to run a simple perl script ./test.pl under /var/www or
/var/www/cgi-bin, but no output showed
while i can run it under / without any problem
the permission of file is
[root@server cgi-bin]# ls -l test.pl
-rwxrwxrwx 1 root root 92 Nov 7 19:52 test.pl

if i run it like this ./test.pl no output, but if i run it perl
test.pl it will show me the output

root@server cgi-bin]# ./test.pl
[root@server cgi-bin]# perl test.pl
hello
/var/www/cgi-bin
[root@server cgi-bin]#


if i tried it again and run it under / directory it will run without
any problem


[root@server /]# ./test.pl
hello
/

[root@server /]# perl test.pl
hello
/

[root@server /]#

script content:

[root@server /]# cat test.pl
#!/usr/bin/perl -w
print "hello\n";
print `/bin/pwd` or die "can't run pwd\n";
print "\n";
[root@server /]#


Sent via Archivaty.com