How to activate SSI - Server Side IncludesThis is a simple process as documented in the
Apache ManualFirst start WAMPServer
Using the wampmanager menus edit the httpd.conf file.
- wampmanager -> Apache -> httpd.conf
Find this section
<Directory "d:/wamp/www/">
#
# Possible values for the Options directive are "None", "All",
# or any combination of:
# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
#
# Note that "MultiViews" must be named *explicitly* --- "Options All"
# doesn't give it to you.
#
# The Options directive is both complicated and important. Please see
# [httpd.apache.org]
# for more information.
#
Options Indexes FollowSymLinks
#
# AllowOverride controls what directives may be placed in .htaccess files.
# It can be "All", "None", or any combination of the keywords:
# AllowOverride FileInfo AuthConfig Limit
#
AllowOverride all
#
# Controls who can get stuff from this server.
#
# onlineoffline tag - don't remove
Require local
</Directory>
And change this line
Options Indexes FollowSymLinks
to
Options Indexes FollowSymLinks Includes
Not just any file is parsed for SSI directives.
You have to tell Apache which files should be parsed.
You can tell Apache to parse any file with a particular file extension, such as .shtml, with the following directives:
Now find this section of httpd.conf
#
# Filters allow you to process content before it is sent to the client.
#
# To parse .shtml files for server-side includes (SSI):
# (You will also need to add "Includes" to the "Options" directive.)
#
#AddType text/html .shtml
#AddOutputFilter INCLUDES .shtml
And remove the comments on these 2 lines
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
If you have coded SSI instructions in a file with a .html extension then you would use
AddType text/html .html
instead of .shtml
Now restart the Apache service so it can pick up these config changes.- wampmanager -> Apache -> Service -> Restart Service
the icon should go from Green to Orange and then back to Green.
If it does not return to Green, you have made a mistake, edit the httpd.conf file again and find your mistake.
---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>Read The Manuals Apache --
MySQL --
PHP --
phpMyAdminGet your Apache/MySQL/mariaDB/PHP ADDONs here from the
WAMPServer alternate Repo-X-X-X-
Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-