Jump to content

Apache and SSIs


Guest SDMF
 Share

Recommended Posts

I have apache installed and working, but for some reason SSIs are not being parsed.

 

These are the only changes I made from the default httpd.conf:

 

added this below the Directory entry for "/"

<Directory /home/httpd/htdocs> # DocumentRoot

   Options Includes -Indexes

   AllowOverride None

</Directory>

 

uncommented these lines already written into httpd.conf:

    AddType text/html .shtml

   AddHandler server-parsed .shtml

 

the file I am including the ssi file in is a .shtml file, and I am using this format for the include:

<!--#include file="relative/path/to/file"-->

 

I checked the attributes, all the directories are 755, and all text files and images are 644, so it doesn't appear that it can't stat the files.

Link to comment
Share on other sites

I think you should comment out the Addtype and AddHandler for SSI because Mandrake uses mod_ssi doesn't it? therefore its a *part* of apache already ...

 

I think ... or maybe I'm full of crap :? :P

Link to comment
Share on other sites

yes .. on further inspection .. this is what I have

    # To use server-parsed HTML files

   #

   AddType text/html .shtml

   AddHandler server-parsed .shtml

 

and this

 

<Directory /var/www/html/loudas.com>

   Options Indexes FollowSymLinks MultiViews

   AllowOverride All

   Order allow,deny

   Allow from all

</Directory>

 

and it works fine

Link to comment
Share on other sites

Ya know what, I'm a dumbass :) I had manually put in a <Directory> section in there, right below the one for "/", and I didn't realize that there was already one there for that directory, right below it. There were so many comments that they just looked like individual statements at first glance. At any rate, the entry that was already there did not have the Includes option enabled, and since it was right below the one I put in, it overrode it.

 

It's all working now, thanks.

Link to comment
Share on other sites

I've added myelf to group apache, I thought that would give me access to /home/httpd/htdocs. Is there some other way I should be granting myslef access, or is it bad practice to give anyone other that root access to the DocumentRoot directory?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...