The Silicon Guide To
Using Server Side Includes
Anyone who attempts to build a web site will quickly
notice how tiring it can be to maintain it, especially when there are hundreds of pages.
For instance, if you choose to have a menu bar, you will have to edit every single
page on your site, every time you choose to modify it. It can also become
frustrating to find out you forgot to modify that "Last Modified" message you
decided to post at the bottom of every page on your site.
Using Server Side Includes greatly reduces the
amount of labour required to maintain a site. But what are they? SSI's are
simply comments that you can insert into your HTML code. When the server reads your
html page, before sending it to the client's browser, it will check every line of it and
"parse" any SSI comments it may find, replacing them with their appropriate
content. Since they are nothing more then comments, if your server does not have
Server Side Includes enabled, or doesn't support them, your page will appear as it should,
except without the SSI content you may have included, and no error will be displayed.
It is also important to take note that in the world
of computer's, as in the real world, nothing is free. Since the server has to read
through every single page, and check to see if their are SSI commands (comments), having
SSI enabled can dramatically increase the strain on your server and even slow it down
noticeably. For this reason, you should not use too many SSI commands in your pages
(definetly not more than 20 per parge), as well as make sure your server is powerful
enough to handle the traffic your plan to have.
Because of this, many server administrators have set
up their web software only to parse pages with a certain extension; most often .shtml or
.shtm. This way the server only has to process those pages that actually use Server
The Echo Command
The Config Command
Executing CGI Scripts
SSI Hosting and Conclusion