Page 1 of 1

SSI Not Working

PostPosted: 08. March 2010 15:14
by regisb50
I cannot get SSI to work in anything except the default XAMPP htdocs directory. I am using the system to serve as a local web host for testing before publishing the sites to an external web service.

I am working with a virtual machine running under VMware Workstation 6.5.3. I have loaded Ubuntu 9.1 and XAMPP 1.7.3a.

I have defined multiple virtual hosts for Apache in the directory /home/www/. For each site I created the directories:

/home/www/www.mysite.localhost/cgi-bin
/home/www/www.mysite.localhost/htdocs
/home/www/www.mysite.localhost/logs

For each site I edited hosts to contain the line "127.0.0.1 http://www.mysite.localhost"

And of course I uncommented the line in /opt/lampp/etc/httpd.conf: "Include etc/extra/httpd-vhosts.conf"

Last I edited /opt/lampp/etc/extra/httpd-vhosts.conf to contain the Virtual hosts ServerName, DocumentRoot, ...

I access my sites from Windows using http://www.mysite/localhost (I add a line the hosts file on these computers: 192.168.xxx.xxx http://www.my.localhost).

I test SSI functionality using the test file, test.shtml:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<HTML>
<HEAD><TITLE> Test Server Side Includes </TITLE></HEAD>
<BODY BGCOLOR="#FFFFFF">
Current Date: <!--#echo var="DATE_LOCAL" -->
<P>Document Name: <!--#echo var="DOCUMENT_NAME" -->
<P>Environmental Variables:<BR>
<PRE><!--#printenv --></PRE>
</BODY>
</HTML>

If I don't get any date in the dislayed page SSI is not working.

SSI works when I put this file in the /opt/lampp/htdocs folder.

However, when I place it in my folder, /home/www/www.mysite/localhost SSI does not work.

All the normal web functional appears to be working in my personal web sites.

Any idea why SSI is not working in the specific folders?