Web Design information, learn all there is to know about web design.

A Beginners Guide to Server Side Includes


An Introduction to Server Side Includes

Beginner? That's OK!

While much has been written about Server Side Includes (SSIs -also known as Virtual Includes) much of this information is designed for intermediate to advanced webmasters. This article is aimed at beginners. It is assumed that the reader has no prior knowledge of scripting languages, servers, or any other advanced computer skills. This article will introduce the reader to SSIs and explain how they are used in web site development. SSIs are guaranteed to save you time as your web site develops and changes over time.

Servers: just a place for your stuff?

It is important to understand that all the code for your website is stored remotely on a computer called a server. On a very basic level, the server (remote computer) is just a place where you can store the files on the "net." These files would typically contain your web site's HTML code and possibly some files containing pictures or graphics.

For example, a very simple web site might consist of 5 web pages with five corresponding files that are stored on the server. One file is named index.html and we will have four additional files. These files might be named about-me.html , education.html , resume.html , and portfolio.html. We'll say that this simple 5 page web site is run by a freelancer who uses this site as a kind of virtual advertisement.

Servers Part 2: more than storage?

We have established that the server functions as a storage place for our files, but it is important to recognize servers can also do things. Similar to the operating systems software on our personal computers, servers have software that allows them to access and organize files. Servers can also carry out more advanced functions. Take, for example, what the server does when someone visits the root directory of your site; the server automatically loads your index page (e.g., index.html, index.php, index.asp). This is a very simple example of something that happens on the "server side."

Why do I need includes?

Now that we understand that remote servers have software on them capable of carrying out certain tasks, we can turn our attention to the "includes" portion of the equation. What are includes? Let's take our hypothetical web site that serves as an advertisement for our imaginary freelancer. Imagine that the freelancer designs a left hand navigation menu so that people can easily browse all five pages of his site. Therefore, each page of this site contains the code for the navigation bar. Imagine that a few months after launching this web site, our freelancer wants to add a Frequently Asked Questions page. Our freelancer now has to update the navigation bar code in each of his five existing pages. Now there are six pages with this same navigation bar code. A month later our freelancer wants to add a self-written article to his site. Once again every page on the site needs to be updated. Imagine having a site with 100's of pages. Do you want to manually update 100's of pages of code? These are the types of situations where virtual includes can save you hours of time.

What are we including on the server side?

Perhaps it would be better to think of includes as "modules" that we can insert into our web pages. These modules (or "includes") are usually just text files that contain HTML code (although they can be other file formats). The code inside these files can be inserted anywhere in a page simply by using an include command. For example, imagine for a moment that our freelancer had the foresight to realize that the navigation menu would change at some point in the future. Instead of putting the code for the navigation menu into each individual page, the freelancer placed this code into a separate file. For the sake of example, we can call this file nav-menu.html Our freelancer can now simply place an "include" command that refers to the nav-menu.html anywhere he/she wants to place this menu. The advantage of this is becomes apparent when our freelancer needs to modify the navigation menu. Just one file needs to be edited, nav-menu.html, and all the pages containing "include" refering to this file will automatically update themselves. This time savings is the primary advantage of using includes.

OK, I get it, but what does an include look like?

Even though this is not a "technical" article, many of you are probably wondering what an "include" looks like. Therefore, one example for PHP is included below. Please note PHP is just one type of scripting language that can be used, depending on what your server is running. In this example, the code contained in the file "nav-menu.html" will be inserted into any web page where the following code is placed:

Keep in mind that, for technical reasons, server side includes will never be visible when you view the source code for a page in your browser. This is because the include happens on the server (before presenting the resulting code to the browser). This makes the use of SSIs invisible to browsers, bots, spiders (which is why they are search engine friendly)

Summary

The catch-22 of server side includes is that the need for them only becomes apparent when faced with the task of updating tens or hundreds of pages of code. There are many resources on the web that will instruct you how use virtual includes, and procedures will vary depending on the type of scripting language supported by your server (e.g., ASP, PHP). Hopefully you now understand Server Side Includes and how they can benefit the webmaster.

About the authors:

This article was written by the editors of the Kabooli Internet Directory. This article may be used freely in opt-in publications and websites as long as the article not changed in any way and all links in the Authors section are active . A courtesy link to any online posting would be greatly appreciated and can be sent to the editors of the Kabooli Directory by using the Kabooli Internet Directory Contact Form


MORE RESOURCES:
Web Development Company- Boon to Online Business - lonad News

Web Development Company- Boon to Online Business
lonad News
The web development company plays a pivotal role in creating a vibrant on line presentation for the business organization so that it can generate more ...


Michael Jenkins promoted to Business Analyst for Drake Software's Web ... - Accounting Software 411 (press release)

Michael Jenkins promoted to Business Analyst for Drake Software's Web ...
Accounting Software 411 (press release)
Michael Jenkins, a 10-year Drake Software veteran, was recently promoted to the position of Business Analyst for the company's Web Development Department, ...


Motorola acquires web development firm to focus on Android development - Mobile Burn

PC World

Motorola acquires web development firm to focus on Android development
Mobile Burn
Motorola has purchased a firm that creates web applications called 280 North, according to Tech Crunch, whose sources say Motorola paid $20 million for the ...
Motorola Acquires 280 NorthErictric

all 69 news articles »

The Web Development Kent Has Been Waiting For Lands Early - TMCnet

The Web Development Kent Has Been Waiting For Lands Early
TMCnet
JB Creative Marketing, which offers a full spectrum of modern marketing solutions for the Internet business, views its web development Kent ...

and more »

Chrome 6 Arrives, Just in Time for Cake - Wired News

Chrome 6 Arrives, Just in Time for Cake
Wired News
This article originally appeared on Webmonkey, Wired's site for all things web development, browsers, and web apps. Follow Webmonkey on Twitter. ...

and more »

Affordable PHP development service from Web development India - Release-news.com (press release)

Affordable PHP development service from Web development India
Release-news.com (press release)
Get affordable PHP development services from Web development India. We at Web development India have an expert team of PHP developers who knows the nuance ...


Audit finds PG&E smart meters accurate - CNET

CNET

Audit finds PG&E smart meters accurate
CNET
He started at CNET News in 2002, covering IT and Web development. Before that, he was executive editor at IT publication InfoWorld. ...

and more »

Cisco buys Arch Rock in smart-grid push - CNET

CNET

Cisco buys Arch Rock in smart-grid push
CNET
He started at CNET News in 2002, covering IT and Web development. Before that, he was executive editor at IT publication InfoWorld. E-mail Martin.

and more »

Affordable PHP ASP NET Developer Programmer for a Complete Web Development - lonad News

Affordable PHP ASP NET Developer Programmer for a Complete Web Development
lonad News
The professional web development are absolutely dependent on various technologies like PHP, ASP NET software, etc. as all these updated technologies are ...
OPS offer Affordable Web Development Services for Experts Web DeveloperOnline PR News (press release)
Hire PHP Programmers At PHP India For Max Outsourcing BenefitsFPRD (press release) (blog)

all 4 news articles »

Web Development Company: ioVista Introduces Cost Effective Web Development ... - PR Urgent

PR Urgent

Web Development Company: ioVista Introduces Cost Effective Web Development ...
PR Urgent
Web Development Company: Companies can now look forward to exceptional web development services. Web Development Company: ioVista has experience with a ...

and more »

Google News

RELATED ARTICLES
Website For The Company Store
If your company own one or more stores, you might be wondering if it would be a good idea to have a website. You might also be wondering if a website for the company store would be profitable for your business.
How to Handle Web Surfers Who Disabled JavaScript
There are hundreds of millions of Web surfers today. Each of them uses one of multiple web browsers available now.
Ten Major Tips to Develop a Multilingual Web Site to Work
If you are living in a country that its native language is something rather than English language, then you may like to develop your website to offer content in the language of your own country.There are millions of websites on the Internet that are all in English language but there are billions of people on the earth that speak in a different language and are not familiar with English language.
Topics to Add When Creating an Alternate and Modern Medicine Web Directory
Alternate medicine finds its own place in the hearts and minds worldwide and has a separate following to back its existence. There are many subcategories that could be added to the modern and alternate medicine website directories.
Find the Purpose of Your New / Proposed Website
Absolutely everything stems from the purpose of your website - selection of hosting, programming, graphic design, copywriting, internet marketing, autoresponder service, and e-commerce. So it's very important to establish the purpose of your business website first.
Up The Sandbox!
Go to any internet marketing forum you want these days andone of the topics is sure to be whether or not there is a"sandbox" at Google where new sites are forced to come andplay for 3-6 months before joining the ranks of ranked andsearched results. On the surface it would appear that thisis so.
Getting a Web Site Can Be Fast, Easy, and Inexpensive When You Know Your Options
So what do you do if need to get a web site but you're not sure how to go about getting one. The good news is you have several options.
Web Measurement: What You Don't Know Would Make A Great Book
"What's in it for me?" you ask. "Why should I measure how people use my website? How does it help and what does it all mean?" The purpose of this article is to try to give you some insight into effective web measurement and to talk about the most important page of any website, the landing or home page.
Your Future Profit Is In The Stars
You don't believe in astrology but you check your horoscope in the newspaper just for fun. Me too.
10 Tips For A Successful Website
Have you ever thought the secret behind the success of most of the famous sites. Do you ask yourself these questions.
What is SQL?
What is SQL? SQL stands for Structured Query Language and is the lingua franca in the database world. SQL is a standard that is used by all database vendors and programmers to define, extract and access the information that is stored in databases.
Nonsense! Why Do I Need a Website?
"I don't sell anything online, I don't advertise online, in fact I don't really even know how to use a computer..
Server Stats - Analyzing Traffic To Your Site
Analyzing traffic to a site is a key factor in tweaking search engine optimization and marketing campaigns. Determining how people get to your site is critical.
Creating Dynamic Website Content with PHP - MySQL
Fresh website content for your visitors can be of real benefit when attempting to generate repeat traffic. Most webmasters, however, just don't have enough spare time to frequently update or rebuild their pages manually.
5 Tips For A Better Website
Having an eye catching website is great, but are you optimizing your website to allow the best performance possible? I receive several emails a day from clients asking how they can get more hits to their websites, what can be done to increase sales, and how to prepare their sites for search engines. There are very simple things that can be done to help your website perform its best.
The Problem with Automated Accessibility Testing Tools
An automated accessibility tool is a piece of software which can test a web page, or even an entire website, for accessibility. Automated accessibility tools are useful because they can save you a huge amount of time.
Dreamweaver 8 Preview
August 8 2005, Macromedia announced a release of Studio 8. Based on the feedback of previous users, Macromedia made it's already very powerful software even better.
Maintaining Your Business Website
QUESTION: Should I build and maintain my business Web site myself or pay someone else to do the work for me? -- Wesley L.ANSWER:When you say, pay someone else to do the work for you, Wesley, I am going to assume that you are talking about hiring a professional Web site designer to do the work and not your next-door neighbor's teenage son.
Developing A Website: 10 Tips For Getting Started
1. Be clear on your purpose.
Developing State-enabled Applications With PHP
Installment 1Developing State-enabled Applications With PHPWhen a user is browsing through a website and is surfing from one web page to another, sometimes the website needs to remember the actions (e.g.

home | site map
 

home : domain name : web design : e-commerce : smart update : optimization : promotion
logo design : samples : cheap web hosting : free quote : about us : contact us : privacy policy : resources

Check out our articles section:
Web Design : Web Hosting   : Web Development   : SEO : OsCommerce Manual  : X-Cart Manual
 


© copyright 2002-2006 | i5networks.com - A Bailey Mac Media Company| all rights reserved

© 2006