[BlueOnyx:19369] Re: Help with SSI & CGI on 5209R
Michael Stauber
mstauber at blueonyx.it
Fri Mar 18 22:38:30 -05 2016
Hi Chris,
> So if I remove this from the vhost conf file, the pages will display
> again, but still no parsing of the CGI. Nothing in the logs, either.
> PerlResponseHandler ModPerl::Registry
I just checked and you're right: This was a stupid idea. :-(
Build the config changes back to what they were. I got it working this way:
In the Vhost container of the Apache config I have the standard stuff:
CGI on, SSI on and PHP+mod_ruid2:
# BEGIN WebScripting SECTION. DO NOT EDIT MARKS OR IN BETWEEN.
<Directory /home/.sites/28/site1/web>
AddHandler cgi-script .cgi .pl
Options +ExecCGI
</Directory>
AddHandler server-parsed .shtml
AddType text/html .shtml
<FilesMatch \.php$>
SetHandler application/x-httpd-php
</FilesMatch>
<IfModule mod_ruid2.c>
RMode config
RUidGid s28_admin site1
</IfModule>
# END WebScripting SECTION. DO NOT EDIT MARKS OR IN BETWEEN.
This is my test.shtml file for the SSI:
]# cat test.shtml
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html>
<head>
<title>Test</title>
</head>
<body>
<pre><!--#exec cgi="/test.cgi" --></pre>
</body>
</html>
It will only get parsed correctly if it has the extension *.shtml.
And a minimalistic Perl script named test.cgi with this in it:
]# cat test.cgi
#!/usr/bin/perl
print "\n\nHello World!";
That works. Provided the HTML file has the ending *.shtml and the Perl
script has the extension *.cgi. The extension *.pl does NOT work.
So the easy fix for you would be to renamed your *.pl to *.cgi to get it
to work.
--
With best regards
Michael Stauber
More information about the Blueonyx
mailing list