Server Side Includes, Search Engines, and SEO

What does a Server Side Include do?
Server side includes allow you to (dare I use the word) include a remote file in the current page. The server constructs the page on the fly. When a browser or search engine spider comes through they see the whole page as one unit.

Why Should I use Server Side Includes?
They make it extremely quick to update navigation and other common page elements by only changing one file.

Are Server Side Includes Evil?
Server side includes were a bad thing in the past. Slower server speeds would sometimes cause errors when a spider spidered the page. With faster server speeds the server side include is no longer a problem. On sites with a large amount of traffic SSI will slow down your server speed ever so slightly.

What do Server Side Include Requests look like?
<!--#include file="navigation.htm" -->
if the SSI file is in the same directry as the file calling it, or
<!--#include virtual="/globalnavigation.htm"-->
if the SSI file which is to be included is in the root directory. Using virtual causes the server to look for the file location based on the root URL.

How do I use a Server Side Include?
To use server side includes you must change your file path to .shtml .shtm or something with the .s at the begining to tell the server it needs to construct the page. Place the include file in the code where you want it to show on the page.
Note: you can controll the layout using an external CSS sheet if you like.

Why Changing Filepaths is Bad
The problem with changing filepaths is that you can lose much of the inbound link popularity you have built up with your site. Any links to the root domain will still be there, but interior links fall away. Blindly changing filepaths is extremely bad:

  • You lose link equiyy.

  • People who were linking to you end up owning a bunch of broken links.

How do I Use SSI without Changing FilePaths?
Our good friend .htaccess is here again to save the day.

Here is the .htaccess file you should use to allow a server to parse .shtml and parse other file extensions as .shtml

AddType text/html .shtml

AddHandler server-parsed .htm (.htm is whatever extension you are using)

AddHandler server-parsed .shtml

Options Indexes FollowSymLinks Includes

Published: March 15, 2004 by Aaron Wall in seo tools

Comments

Add new comment

(If you're a human, don't change the following field)
Your first name.
(If you're a human, don't change the following field)
Your first name.
(If you're a human, don't change the following field)
Your first name.

New to the site? Join for Free and get over $300 of free SEO software.

Once you set up your free account you can comment on our blog, and you are eligible to receive our search engine success SEO newsletter.

Already have an account? Login to share your opinions.