Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change

Running SSI

by Anonymous Monk
on Oct 27, 2009 at 09:46 UTC ( #803403=perlquestion: print w/replies, xml ) Need Help??
Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Hi monks. What do I need to do to enable SSI? I've added the required entries in httpd.conf file but SSI isn't working. My .shtml files are in the cgi-bin folder. Here's what my conf file looks like
<Directory "C:/Program Files/Apache Software Foundation/Apache2.2/cgi- +bin"> AllowOverride None Options Includes Order allow,deny Allow from all AddType text/html .shtml AddHandler server-parsed .shtml </Directory>

Here's a simple code, is this correct?
<html> <head><title>Spain</title></head> <body> Today's date is <!--#echo var="DATE_LOCAL" --> </body> </html>

Replies are listed 'Best First'.
Re: Running SSI
by moritz (Cardinal) on Oct 27, 2009 at 09:50 UTC
    On Apache 2 this works for me:
    AddOutputFilter INCLUDES .shtml

    (instead of the AddHandler directive).

    Perl 6 - links to (nearly) everything that is Perl 6.
      Ok. I've tried adding AddOutputFilter also but it still isn't working. Can someone who has SSI enabled post their entire httpd.conf file?
        dude, this is way off - is this the apache help site?

        Make sure at some point you do load the include module..

        LoadModule include_module modules/
        In your Directory entry, likely for your /var/www/html if you don't host mult sites.. If you want to allow parsing in html as well as shtml files..
        AddOutputFilter Includes html
        And stop using windows.
Re: Running SSI
by scorpio17 (Abbot) on Oct 27, 2009 at 15:36 UTC

    Have you read the documentation?

    Common problems are usually due to file/directory ownership and/or permission settings (on unix). Since you're running on Windows (the 'C:' in your directory path was a dead give-away), there may be additional gotchas to watch out for - try google.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://803403]
Approved by moritz
and a kettle whistles...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (10)
As of 2018-06-22 13:32 GMT
Find Nodes?
    Voting Booth?
    Should cpanminus be part of the standard Perl release?

    Results (124 votes). Check out past polls.