Rainbo Design's No-Frames Navigation System
Server Side Includes

Server Side Includes are a powerful tool for webmasters hosted by systems using the Apache server software. It allows you to add intelligence to your webpages without having to rely on client-side browser capabilities, but it can also easily be used even by non-prorgammers to insert the content of external files into your webpages.

The contents of the menu seen here on the left is actually stored in a separate HTML file. You can update the navigation on your whole site, just by editing this single external file. Its even easier than using frames because you don't have to worry about the TARGET attribute, and you can add links to pages outside your own site without having to worry about them loading inside your frameset.


To impliment Server Side Includes, you need to be on an Apache-based server. Use my Server Response Header Checker and enter the URL for your website. The information returned by your server will include the name of the server software. If it mentions 'Apache', you're in business. If it mentions Microsoft, you're out of luck.
Next you need to make sure that your pages will be scanned by the Apache server software for server directives. Ordinarily, Apache will only scan pages that use the '.shtml' file name extension. But you can add an '.htaccess' file to the root directory of your site that will tell Apache to scan other file types. I recommend adding the following lines to your new or existing .htaccess file:

Options +Includes
Options +FollowSymLinks
AddHandler server-parsed .htm .html

This code tells Apache two important things: (1) Enable Server Side Includes, and (2) Scan files ending in either '.htm' or '.html' for server directives.

Then you can add the directive to include your menu file by adding the following code to your HTML pages:

<!--#include virtual="menu.html" -->

That's all. Just change the filename to the one you use for your HTML file that contains the code for your menu and upload it all to your site.



Click here to return to the Rainbo Design software menu.

No-Frames Navigation System© software Copyright (C) 2003 by Richard L. Trethewey. All rights reserved.


Rainbo Design's Software Home Page

NoFrames Navigation Main Page

Server Side Includes

External JavaScript

<IFRAME>s

PHP Version