---------- Original Message ----------------------------------
From: "Brett W. McCoy" <[EMAIL PROTECTED]>
Date: Thu, 10 May 2001 09:39:29 -0400 (EDT)

>On Thu, 10 May 2001, Chip Wiegand wrote:
>
>> I have the permissions set to 755, so it should be executable. When I
>> try ./formparser.cgi I get ./formparser.cgi: not found, but when I
>> run perl formparser.cgi it runs fine. I noticed when doing ls -la that
>> the four scripts in the cgi-bin all have an asterisk by their name, I
>> don't recall what that means. Could that have anything to do with it?
>
>The asterisk is just a visual aid from ls to indicate that the file is
>executable (if you have color enabled for ls, they should be green also).
>If it works by explicitly using the Perl interpreter but not without,
>either your shebang line is wrong or the file isn't exectuable.
>
>-- Brett

Here's some more info, I'm at work now and experiencing the same problem on differant 
scripts -

-This is one script I'm having the above problem with -
bash-2.04$ perl -c umail.cgi
umail.cgi syntax OK

-This is where perl lives -
bash-2.04$ which perl
/usr/bin/perl

-This is the first line from the above non-working script -
#!/usr/bin/perl
#####################

-I then wrote this little ditty -
#!/usr/bin/perl -w
print "Content-type: text/html\n\n";
print "<body><head><title>My first script</title></head>";
print "<body bgcolor=\"white\"><h1>Hi there!</h1></body></html>";

And ran it from the browser - http://localhost/cgi-bin/test.cgi
and it ran fine. Shows a big Hi There! 

Here is the permissions setup-
-rwxr-xr-x   1 chip  wheel    187 May 10 08:20 test.cgi
-rwxr-xr-x   1 chip  wheel  11508 May 10 08:32 umail.cgi

I don't know what I am doing wrong, it's probably something really simple and obvious, 
which is why it's being missed. 
I pulled all the ^M's out of the umail.cgi, but that didn't 
make any differance.

--
Chip  

Reply via email to