[ILUG] Perl and Apache
Kevin Philp
kevin at cybercolloids.net
Tue May 4 13:16:28 IST 2004
To answer all the replies:
Script is executable:
-rwxr-xr-x 1 kevin kevin 1076 May 4 12:11 index.pl*
The script starts with:
#!/bin/sh
echo DEFANGED.0
exit
#!/usr/bin/perl
print "Content-type: text/html\n\n";
The #! line is correct, I checked.
I changed the directives to
<Directory "/var/www/html/teerhatavaz">
AllowOverride All
Options +ExecCGI
AddHandler cgi-script .cgi .pl
</Directory>
I still get the same response. In konqueror I just get a copy of the raw
script. It appears to send it to me as plain text and skip sending it to perl
for processing.
Kevin.
Kevin Philp wrote:
> I want to run a few perl scripts outside of the usual /per/ or
> /cgi-bin/ directories and in the main web tree. Perl works fine from
> the /perl/ directory but I can't get it working in any other
> directories. I followed the instructions in the Apache manual and
> added
>
> <Directory "/var/www/html/teerhatavaz"> Options +ExecCGI AddHandler
> cgi-script cgi pl </Directory>
>
> But just got the source code thrown out. I also tried
>
> <Directory "/var/www/html/teerhatavaz"> Options +ExecCGI
> AddHandler perl-script cgi pl SetHandler perl-script
> </Directory>
A Lack of AllowOverride somewhere before ?
> Doesn't appear to be processing the scripts as perl. Any ideas
> welcome?
Does it sends you the raw perl source ?
Is your script chmod ogu +x ?
Does your script start with #/usr/bin/perl ?
--
Thomas Pedoussaut
Dublin IRLANDE
http://irlande.staffeurs.org/
More information about the ILUG
mailing list