Article ID: 2520, created on Oct 29, 2007, last review on May 10, 2014

  • Applies to:
  • Pro Control Panel Linux

AdditionalInformation

View Knowledge
Knowledge ID 1302
Product : WEBppliance for Linux
Version : 3.5.0
Topic : FAQ

Title
SSI doesn't work in the cgi-bin directory

Summary
SSI doesn't work in the cgi-bin directory

Prevention


Details

Previously in WEBppliance 3.1.x you could place .shtml files in the cgi-bin directory where it would be parsed. However after upgrading to Pro 3.5, this will stop working because in the WEBppliance Pro 3.5 uses Script instead of ScriptAlias in the file /etc/httpd/conf/site#/cgi. You can fix this by copying your .shtml files into the html directory or  you can use one of these two options.

Option #1:

Create a .htaccess file in the cgi-bin directory with something like:

SetHandler None
Options +Includes
AddType text/html .html .shtml
AddHandler server-parsed .shtml
AddHandler cgi-script .pl .sh .sh .cgi

The important part is to put all of the extensions (.pl, .sh, etc) in the AddHandler cgi-script line that you plan to use as CGIs. Otherwise they won't get executed. Now go to the URL and the SSI should work.

Option #2:

Alternatively, you can use the ScriptAlias instead by doing: (replace all instances of site# with the actual site number):

  1. Login as root to the server  
  2. cd /etc/httpd/conf/site#  
  3. cp cgi cgi-custom  
  4. EditVirtDomain -c cgi,off site#  
  5. Edit cgi-custom and make it look like:

ScriptAlias /cgi-bin/ /home/virtual/site#/fst/var/www/cgi-bin/
     <Directory /home/virtual/site#/fst/var/www/cgi-bin>
          AllowOverride All
     </Directory>
     <Directory /home/virtual/site#/fst/home/*/public_html/cgi-bin>
           Options +ExecCGI
           SetHandler cgi-script
           AllowOverride All
     </Directory>
     SetEnv SITE_CGIROOT /home/virtual/site#/fst/var/www/cgi-bin

Now restart httpd, and go to the URL with the SSI and it should work.


Attachments


Related Knowledge

Related Links
 
Last ModifiedUsageSatisfiedLast Used
8/20/2004 12:56:52 PM45 10/11/2007 6:37:59 AM

4cc899da08664637a8bc437308d3ddd7 3ccb419cf98083f3bb45808fba8dbc7c 6311ae17c1ee52b36e68aaf4ad066387

Email subscription for changes to this article
Save as PDF