Welcome Guest. Please Login or Register  


You are here: Index > AMPPS > General Support > Topic : enable ssi and shtml



Threaded Mode | Print  

 enable ssi and shtml (8 Replies, Read 7417 times)
aarondeen
Group: Member
Post Group: Newbie
Posts: 3
Status:
How do I go about enabling my local ampps to use server side includes and the shtml extension?

I uncommented the AddType text/html .shtml
    AddOutputFilter INCLUDES .shtml
The LoadModule include_module modules/mod_include.so was already uncommented in httpd.conf, and also set to on from the web portal.

I my guess is that I am not doing this step properly:
# (You will also need to add "Includes" to the "Options" directive.)
IP: --   

enable ssi and shtml
bradatefi
Group: Member
Post Group: Newbie
Posts: 2
Status:
I am also trying to figure this out.  I have not been able to locate the documentation that explains how to do this. 
IP: --   

enable ssi and shtml
tidus
Group: Member
Post Group: Super Member
Posts: 1121
Status:
Hi,

Uncomment the following lines in httpd.conf (AMPPS Control Center -> Apache Tab -> Configuration):

Code
AddType text/html .shtml

AddOutputFilter INCLUDES .shtml


Then create a new conf file say i.e Ampps\apache\conf\extra\extra.conf with the following contents : (CORRECT THE AMPPS PATH)

#### Localhost VirtualHost ####

NameVirtualHost 127.0.0.1:80
NameVirtualHost 127.0.0.1:443
<VirtualHost 127.0.0.1:80>
<Directory "C:\Program Files (x86)\Ampps/www">
    Options FollowSymLinks Indexes Includes
    AllowOverride All
    Order deny,allow
    allow from All
</Directory>
ServerName localhost
ServerAlias localhost 127.0.0.1
ScriptAlias /cgi-bin/ "C:\Program Files (x86)\Ampps/www/cgi-bin/"
DocumentRoot C:\Program Files (x86)\Ampps/www"
ErrorLog "C:\Program Files (x86)\Ampps/apache/logs/error.err"
CustomLog C:\Program Files (x86)\Ampps/apache/logs/access.log" combined
</VirtualHost>

###############################

Then open httpd.conf (AMPPS Control Center -> Apache Tab -> Configuration), find the line :
Code
Include conf/extra/httpd-vhosts.conf


and prepend the following line above it :
Code
Include conf/extra/extra.conf


So it will look like :
Code
Include conf/extra/extra.conf

Include conf/extra/httpd-vhosts.conf


Restart Apache.


Edited by tidus : April 1, 2013, 2:12 pm

-----------------------
Follow AMPPS on,
Twitter : https://twitter.com/AMPPS_Stack
Facebook :  http://www.facebook.com/softaculousampps
Google+ : https://plus.google.com/+AmppsStack
IP: --   

enable ssi and shtml
bradatefi
Group: Member
Post Group: Newbie
Posts: 2
Status:
I made the changes and after trying to start the Apache server it says 'Configuration File Changed' and doesn't start up.  Let me know if you have any suggestions.

Thanks,
Brad
IP: --   

enable ssi and shtml
tidus
Group: Member
Post Group: Super Member
Posts: 1121
Status:
Quote From : bradatefi April 3, 2013, 6:51 pm
I made the changes and after trying to start the Apache server it says 'Configuration File Changed' and doesn't start up.  Let me know if you have any suggestions.

Thanks,
Brad


I think there is some issue with extra.conf

Run the httpd.exe from command prompt it will throw an exact error.

E.g :
Code
"C:\Program Files (x86)\Ampps\apache\bin\httpd.exe"


-----------------------
Follow AMPPS on,
Twitter : https://twitter.com/AMPPS_Stack
Facebook :  http://www.facebook.com/softaculousampps
Google+ : https://plus.google.com/+AmppsStack
IP: --   

enable ssi and shtml
aarondeen
Group: Member
Post Group: Newbie
Posts: 3
Status:
:\Program Files\Ampps\apache\bin>httpd.exe
AH00548: NameVirtualHost has no effect and will be removed in the next release C
:/Program Files/Ampps/apache/conf/extra/extra.conf:3
AH00526: Syntax error on line 15 of C:/Program Files/Ampps/apache/conf/extra/ext
ra.conf:
DocumentRoot takes one argument, Root directory of the document tree

c:\Program Files\Ampps\apache\bin>

I have my ampps installed in the program files directory and not the program files (86) directory, so I changed those.  My server also won't start.  Thanks for the help
IP: --   

enable ssi and shtml
aarondeen
Group: Member
Post Group: Newbie
Posts: 3
Status:
ScriptAlias /cgi-bin/ "C:\Program Files (x86)\Ampps/www/cgi-bin/"
DocumentRoot "C:\Program Files (x86)\Ampps/www"
ErrorLog "C:\Program Files (x86)\Ampps/apache/logs/error.err"
CustomLog "C:\Program Files (x86)\Ampps/apache/logs/access.log" combined

I added " before C:/ of the DocumentRoot and CustomLog lines and my server started.
IP: --   

enable ssi and shtml
tidus
Group: Member
Post Group: Super Member
Posts: 1121
Status:
Quote From : aarondeen April 8, 2013, 2:33 am
ScriptAlias /cgi-bin/ "C:\Program Files (x86)\Ampps/www/cgi-bin/"
DocumentRoot "C:\Program Files (x86)\Ampps/www"
ErrorLog "C:\Program Files (x86)\Ampps/apache/logs/error.err"
CustomLog "C:\Program Files (x86)\Ampps/apache/logs/access.log" combined

I added " before C:/ of the DocumentRoot and CustomLog lines and my server started.


Yes sorry for the mistake. Is it working now ?


-----------------------
Follow AMPPS on,
Twitter : https://twitter.com/AMPPS_Stack
Facebook :  http://www.facebook.com/softaculousampps
Google+ : https://plus.google.com/+AmppsStack
IP: --   

enable ssi and shtml
hollowmyth
Group: Member
Post Group: Newbie
Posts: 1
Status:
Digging up this old thread to ask how to do this with the latest version of AMPPS. We have some old pages that use ssi virtual includes and some conditionals that I'd like to just be able to serve up. But, I don't want to keep editing the httpd-vhosts.conf every time AMPPS rebuilds it when I add a new domain. How can I make sure that my "domains" have the Option Includes added to their conf?
IP: --   

« Previous    Next »

Threaded Mode | Print  



Jump To :


Users viewing this topic
1 guests, 0 users.


All times are GMT. The time now is April 25, 2024, 2:26 am.

  Powered By AEF 1.0.8 © 2007-2008 Electron Inc.Queries: 11  |  Page Created In:0.024