Website Maintenance Made Easier – Use include files.

I’m amazed at the sites I work on that aren’t using some basic means of keeping their site up to date.  This can be a time consuming task for anyone, don’t make it harder than it has to be.   One example is the Server Side Include (SSI) code.  It’s an easy piece of code, it works on almost every server technology, and it can make life much easier when you decide to change a section of your site that should be consistent everywhere.

 So what is this magical piece of code:

<!–#include virtual=”filename” –>

That’s it, this tells the browser to go find that file and place it here in the code.  Rather than go on about the code itself I’ll talk about some prime places to use it. 

First, navigation.  web usability has preached for years that consistent navigation allows users to find what they want.  Using SSI allows a web designer to hold themselves accountable to that rule.  Make a navigation and stick to it.  Have every page include that file for it navigation.  The ultimate benefit is when something changes in the navigation, one file can be changed instead of every single page.  It keeps good usability standards and saves time, what’s not to like?

Another place it can commonly be used is in a footer section.  Many sites have copyrights and/or analytic code at the bottom of every page.  Once again, set that up as an include file.  That way if your analytic data or copyright notice needs changed, it gets changed everywhere.  One note on this, if content on a site has a copyright that needs to stay constant it’s a good idea to leave the include file out of that page so it isn’t accidentally changed down the line.

Explore the parts of your site that would benefit the most.  This is not a hard piece of code to use.  Practice with it a bit, I know I had a few hiccups with not putting the right code in the right file at first, but with a little effort that’s easily overcome.   Once the pages are set up to use this, maintenance becomes a heck of a lot easier.

– Eric

Leave a Reply

Your email address will not be published. Required fields are marked *