Using Server Side Includes to Simplify Your Web Design

An "include" file is a piece of code that can be put into a seperate file -- for example -- your navigation bar -- and then "included" in a number of other pages. This has the very useful advantage of allowing you to retain consistency over a very large number of pages, and then make changes to all of those pages by just changing the include file.

For instance, say you want each page in your site to include a short paragraph that uniquely identifies your site. I normally call this a "site-id". It would read something like this:

ForSaleTours.com - provides information and sources for virtual tours for the real estate industry. We explain different methods of combining video and audio to produce virtual representations of your home to enhance its value and to make the purchasing experience of potential buyers better than it otherwise might be.

To set this up so it appears in a host file as an "include", you normally have to do three things:

1. Make sure your server allows SSI (server side includes). If you have access to your web site control panel you should be able to figure this out. Or if not, ask your web host technical support people.

2. Create a "host" file and give it a file extension so your server recognizes it contains include files. A common extension is .shtml

3. Create your include file. It can usually have any of a number of different extensions: .html, .htm, .php, even .txt. This is the file that will be included within other files.

4. Embed the correct code within your .shtml file to point to the include file. If the include file and host file are in the same folder on the server, it will look like this:

<!--#include file="file_name.html"-->

If the include file is located in a different folder (on the same server), the code will look like this:

<!--#include virtual="folder_name/file_name.html"-->

In the above example you have to make sure the relative path to the include file is set correctly.

Now when you want to make a global change to, for instance, your "site-id", you just have to change the include file (once), and this change will be populated through all the pages that include that file.

Include files can be put to many creative uses that allow you to do things that are otherwise very impractical. And if you have a website with a large number of pages, this technique can save you a great deal of time.

For more web design and online marketing tips see the Linknet Marketing Resource Library

Rick Hendershot is a marketing consultant, writer, and internet publisher who lives in Conestogo, Ontario, Canada. He publishes several websites and blogs, including The Linknet Network of Websites. This network provides an inexpensive way to advertise your website, and get as many as 100 low cost links.

In The News:


pen paper and inkwell


cat break through


Dont Overdo it!

Have you ever been to site with so much ad... Read More

Love at First Site: Giving Your Website Visitors the right Impression

Think of the people who visit your site as blind... Read More

Creating Quality Websites

Websites, there are literally billions of them out there in... Read More

How To Choose The Right Web Design Company

1. Size does not equate to competencePeople sometimes assume a... Read More

Use Feng Shui Techniques To Design a Harmonic Website For Your Business

By following feng shui guidelines and techniques, you can build... Read More

How To Write An Effective FAQ Page

Websites that have multiple pages usually have a Frequently Asked... Read More

Use Exclusive Content - When Reprint Articles Dont Do Enough

There is no doubt that reprint articles can serve lots... Read More

Top Ten Website Design Secrets for Internet Marketing Success

When it comes to marketing your website, you should really... Read More

Why Not To Use Web Design Templates For Your Website

In today's age of fast food and high-speed Internet, a... Read More

Web Design: How To Get Your Visitors To Stay

Remember the famous line from the movie Field of Dreams,... Read More

Website Design Firm

Website design firms come in all shapes and sizes.When choosing... Read More

Web Designers Beware!

As a web designer, I have a personal interest in... Read More

Why You Want to Include an FAQ In Your Site

Congratulations! You've got a brand new site and it's doing... Read More

Is Your Site Too Slow? Why Image Optimization Is Critical

Graphics are fun, but if you put in too many... Read More

The Proper Way to Use Images

Most people will agree there is nothing more annoying than... Read More

Top Six Ways To Make Your Visitors To Hate YOU!

We will take a look at why your visitors may... Read More

Freelancers Bite Back!

The Internet has seen an explosion in so called 'lance'... Read More

Stop Sabotaging Your Sales

Do your web pages, sales letters or personal presentations include... Read More

Why a Website Design Speaks Volumes About Your Company?

Whether a business has just got off the ground or... Read More

Increasing Conversions Through Action-Oriented Copywriting

I do site reviews. Needless to say, I see a... Read More

Internet Tip of the Week: First Impressions

First impressions are extremely important if you hope to do... Read More

Good Content Pays!

Traffic to a site can be a blessing or a... Read More

The Brutal Truth

Not too long ago while looking for businesses that do... Read More

Bad Web Design: ActiveX

ActiveX uses an interesting method for enforcing security ... it... Read More

Ten Basic Steps For Building A Web Site That Works

1. Assemble a web site development plan that is integrated... Read More

Choosing Form Over Function Kills Your Site

Never put form over function. Why? Because it's crucial that... Read More

Website Sales: Discover 10 Mesmerizing Insider?s Tricks To Ignite Your Sales

Marketing is not an easy skill to acquire.It requires patience... Read More

Creating Your First Website? Your Options

Creating your own website is great fun! But how is... Read More

5 Instant Tips for More Online Sales

Even after you've managed to bring traffic to your site... Read More

6 Reasons Why A Website Is Crucial To Your Business

Since I'm a web designer, I have a tendency to... Read More

10 Nifty Ways to Prolong Your Visitors at Your Website

Increasing the length of time a visitor is on your... Read More

Flash - To Use Or Not To Use?

Out there in the WWW there are thousands sites using... Read More

Looking for a Web Design Company? Use a Web Design Directory

Your business website tells a lot about your company. A... Read More