Industries Run Your Business E-Business News and Research Community On The Air Marketplace
Search:
Content
 
 
  Search
Products
  Search
 Advanced Search
 Search Help
 Site Map
Shopping Cart
Featured Business Services

Member Center
Register with Office.com

Email
Calendar
Account Information
Sign In/Out


Get our Free Newsletter
Get free Desktop Toys
Take a Tour of Office.com



Perlaccess : Tutorials
Enabling SSI (9.3)
by Jacob A. Wheeler
http://www.bigresources.com

NOTE: The below example is for enabling SSI for the Apache webserver.

There are a few places within your apache httpd.conf configuration file that may need to be modified to enable SSI. I will work my way through my config file, and paste the different areas you may want to modify.
#
# Each directory to which Apache has access, can be configured with respect
# to which services and features are allowed and/or disabled in that
# directory (and its subdirectories). 
#
# First, we configure the "default" to be a very restrictive set of 
# permissions.  
#
<Directory />
    Options FollowSymLinks Includes ExecCGI
    AllowOverride None
</Directory>
You will find the above code near the top of your config file. The most important part is the "Includes" (for enabling SSI) and "ExecCGI" (embedding cgi/perl scripts in SSI calls). AllowOverride tells apache wether or not you want to allow htaccess files to overwrite variables set in this file (httpd.conf).

#
# This should be changed to whatever you set DocumentRoot to.
#
&ltDirectory; /your/home/path/public_html>
#
# This may also be "None", "All", or any combination of "Indexes",
# "Includes", "FollowSymLinks", "ExecCGI", or "MultiViews".
#
# Note that "MultiViews" must be named *explicitly* --- "Options All"
# doesn't give it to you.
#
    Options +Includes +ExecCGI 
#
# This controls which options the .htaccess files in directories can
# override. Can also be "All", or any combination of "Options", "FileInfo", 
# "AuthConfig", and "Limit"
#
    AllowOverride All
#
# Controls who can get stuff from this server.
#
    Order allow,deny
    Allow from all
</Directory>
Another very important part, you will find this shortly after the first part of code. Here you are telling apache exactly which directory (your root directory) to allow SSI calls from. Note the '+' before Includes and ExecCGI, I have found that this is very important on some systems / builds of apache.

ScriptAlias /public_html/ "/your/home/path/public_html"
#
# "/var/www/cgi-bin" should be changed to whatever your ScriptAliased
# CGI directory exists, if you have that configured.
#
<Directory "/your/home/path/public_html">
    AllowOverride All
    Options +ExecCGI
    Order allow,deny
    Allow from all
</Directory>
The above code is similiar to the last, just to give you an idea of the format for creating ScriptAlias directories. This allows you to enable SSI in only a certain dir (within your document root preferably). Again we allow htaccess override any thing set forth in this file.

#
# To use CGI scripts:
#
AddHandler cgi-script .cgi
#
# To use server-parsed HTML files
#
AddType text/html .shtml .html
AddHandler server-parsed .shtml .html
You will find this code shortly after the above code for ScriptAlias's. This tells apache to parse all files ending in .shtml and .html. NOTE: Setting apache to parse .html files as well as .shtml may cause a server speed decrease, as apache needs to parse EVERY html file, and check for ssi calls.

The above may be similiar, but not exactly what your configuration file may look like. If you have any questions please post them on our support forums.

Example SSI Call

<< Back
BigResources Weekly
1-Click-Clipart
Free Clipart Reviews
123 Webmaster
Free Web Tools
A1 Javascripts
Free Java Scripts
Font Files
Free Fonts
Freeware Files
Free Downloads
FreeWebTemplates
Free Website Templates
Fresher Image
Free Clipart
HTML Forums
Free Help
Perl Access
Learn Perl Scripts

 
Free email - Signup Now!

Big Partnership!
The Bigresources.com network has partnered with Office.com!  

Read the details





Perlaccess.com and all content within this site is copyright © Big Resources, Inc.
Mascot team created by Drawshop.com
Help Contact Us Join Our Team Partners About Us Home
Copyright © 1999-2001 Office.com Inc. All Rights Reserved.
Use of this site is subject to Office.com's Terms of Service.
Office.com's Privacy Policy.