junkmail wrote:

>     Hey, so I'm having a weird problem maybe someone can help me with.
> I have a simple perl script named test.cgi that generates html (ie a cgi
> script) which looks like
>
> #!/usr/bin/perl
> # hello.pl -- my first perl script!
> print "Content-type: text/html\n\n";
> print <<"EOF";
> <HTML>
> <HEAD>
> <TITLE>Hello, world!</TITLE>
> </HEAD>
> <BODY>
> <H1>Hello, world!</H1>
> </BODY>
> </HTML>
> EOF
>
> If I type "perl test.cgi" (minus the quotes) the perl script runs.  If I
> type "./test.cgi" I got the error "bash: ./test.cgi: No such file or
> directory"
> If I remove the #!/usr/bin/perl line from the beginning of the perl script
> and "./test.cgi" again it runs but gives a lot of file not found errors.
> I'm guessing that somewhere there is an environment variable I am missing or
> something...  I have perl 5.6 installed and Mandrake 7.1 with the 2.2.16
> kernel.
> Any suggestions???
>
> Thanks
>
> Sam
>
>   ------------------------------------------------------------------------
> Keep in touch with http://mandrakeforum.com:
> Subscribe the "[EMAIL PROTECTED]" mailing list.

Oh I forgot remember to make your script executable chmod a+x test.cgi

Aaron Dancygier


Keep in touch with http://mandrakeforum.com: 
Subscribe the "[EMAIL PROTECTED]" mailing list.

Reply via email to