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.
|
|
|
|
|
|
|
|
|
|
|


Whether you're hiring a designer who has created 10 sites... Read More
1. Use .gifs rather than .jpgs. GIFs are smaller in... Read More
Then it was a choice among crayons, paints and palettes... Read More
Just because you are a small business with an even... Read More
When I purchase something from a web site I first... Read More
On the internet we don't deal with face to face... Read More
Thinking about designing your own website? Think again about adding... Read More
Once, I attempted to create a favicon (the little graphic... Read More
There are several graphic software packages available to help you... Read More
We would all like to have the best looking website,... Read More
1. What's the purpose?The most fundamental thing to do before... Read More
A search for "web design" on Google returns more than... Read More
Even if you're not an accomplished webmaster you can still... Read More
Many people hire professional web site designers for as much... Read More
Square buttons, round buttons, flashy buttons ? will they match... Read More
A website should firstly be searched out by visitors before... Read More
Have you put a lot of effort, time, and money... Read More
Back to basics. Forget funky design, good copywriting is the... Read More
When it comes to marketing your website, you should really... Read More
Since I made the switch 6 months ago to a... Read More
A question we frequently get asked is, "how do we... Read More
You've come up with a great product. You've got the... Read More
Websites, there are literally billions of them out there in... Read More
Getting traffic to your website is not the only factor... Read More
Did you know that many folks make "buying decisions" when... Read More
The landing page or entry page of your visitors is... Read More
FACT: 30 to 60% of visitors tend to drop off... Read More
An ongoing challenge for webmasters today is to provide fresh... Read More
In retailing there is a saying that sales are made... Read More
Here's the single most important part of your website: YOUR... Read More
As an online Entrepreneur you require a successful website.One that... Read More
The internet is full of web design companies pleading for... Read More
If you are trying to sell a product or service... Read More


Well, a logo for your business. Why is it important?... Read More
The time it takes to load your site can make... Read More
When you're self-employed, choosing a website designer is a crucial... Read More
Making your site accessible means making it available to be... Read More
Effective navigation stands out. It's clear, obvious, and highly visible.You'll... Read More
Hire a designer or a programmer for your website is... Read More
Whenever singer John Mayer sings his romantic song, "Your Body... Read More
Well it is not Elvis, that's for sure.I am a... Read More
Being a writer, when I was asked to do some... Read More
Your website design may be affecting your sales in ways... Read More
What colors do you have at your website?Can they make... Read More
Before you take a road trip it is usually a... Read More
What do the key words represent?Key words - these are... Read More
Making a successful online business can be a long and... Read More
Geared Up with a website and lots of energy to... Read More
Favorite icon appears to the left of your link in... Read More
Usability isn't only for Web design. It's also applicable in... Read More
I do site reviews. Needless to say, I see a... Read More
ActiveX uses an interesting method for enforcing security ... it... Read More
1. Use .gifs rather than .jpgs. GIFs are smaller in... Read More
If you are designing a web site for which the... Read More
The first step to starting any Internet business is conducting... Read More
Have you ever thought about the real stories behind all... Read More
Tips to brand your websiteInclude your logo in all pages.... Read More
Here's a really simple way... any novice can create a... Read More
Does your website need a re-design? Here are some questions... Read More
Navigation must be simple. Since it's the backbone of your... Read More
Are you serious about get this website done fast and... Read More
An ongoing challenge for webmasters today is to provide fresh... Read More
QUESTION: My business is very small, just me and... Read More
Just because you are a small business with an even... Read More
Ecommerce is just exploding right now on the Net. More... Read More
A question we frequently get asked is, "how do we... Read More
Web Design |