Using SSI to Boost Efficiency - Enabling SSI (Page 2 of 7 )
If you're using IIS, Server Side Includes are enabled by default for any files with the extensions .shtml, .stml or .stm.
If you're using Apache, you will need to enable SSI manually. In your global configuration, add the following:
This allows SSI to be parsed by the server. To identify which files should be parsed, you also need to inform the server of the new file extension. If you're one of the fortunate ones using Apache 2.0, the following will do the job:
AddType text/html .shtml AddOutputFilter INCLUDES .shtml
If you're like me and still living in the past with Apache 1.3, you need to do the following instead:
This pair of directives tells the server that files ending in .shtml should be processed for Server Side Include directives. Because Apache is the ever versatile server, there is another method called XBitHack. With XBitHack on, files with an executable bit will be processed for includes, just as if the file had the .shtml extension. I haven't used this feature and I have some reservations about marking what is ultimately a text file as executable. This method won't work if you're using Apache under Windows, since the file permission system is too different for an Execute bit to make much sense.