LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Perl CGI problems... (https://www.linuxquestions.org/questions/linux-software-2/perl-cgi-problems-49839/)

mapage 03-14-2003 12:52 PM

Perl CGI problems...
 
The problem is that when I open a perl CGI (As simple as hello world) from a web browster, I get the perl source code instead of hello world.

I'm using a stock Redhat 8.0 install. In the /etc/httpd/conf.d I have perl.conf which is supposed to load mod_perl (I think...) so I can't figure out why it isn't working. The file extension of the perl file is .cgi.

Can anyone help me?

mapage 03-14-2003 01:09 PM

Okay... Think I figured it out. I tried to run the CGI from the CGI directory, which worked. From there I took the # off of the line in the httpd.conf which read

AddHandler cgi-script .cgi

So now it works. Thanks for everyone who though of helping...

AltF4 03-14-2003 01:25 PM

check your httpd.conf for something like this:
--------------------------------
#
# set /cgi-bin for CGI execution
#
<Location /cgi-bin>
AllowOverride None
Options +ExecCGI -Includes
SetHandler cgi-script
</Location>
--------------------------------

Does the directory of your CGI program have the +ExecCGI option set ?


All times are GMT -5. The time now is 06:28 PM.