Web Development Information |
|
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: Help with Tax Calculator SitePoint UA Little Rock Student Gains International Experience as Web Development Intern in Australia University of Arkansas at Little Rock Welcome animation conflict with barba js SitePoint Web Design and Development Muskegon Community College Button Styles Not Working On Phones SitePoint Will Ukraine nuke Russia if Donald Trump cuts aide? Reports say the country is just months away from build The Economic Times From accounting to web development: Meet this Ironhack grad making big strides in programming Refresh Miami Northeastern grad goes from schooling to working full time at web development startup he created Northeastern University Woocommerce_before_shop_loop related SitePoint 17 Best Tech Website Designs in 2024 DesignRush The future of programming SitePoint Register for AIM’s Free Web Development Course by Sept. 10 Silicon Prairie News How Much does Website Development Cost in 2022? Appinventiv Latest News: Rising Senior Uses Computer Science Coursework to Thrive in Web Development Role Muhlenberg College Data display problem SitePoint Wordpress-Gutenberg/React: MediaUpload? SitePoint Best Website Development Tools for 2024 DesignRush Best web development tool of 2024 TechRadar Best PHP Frameworks for Web Development in 2024 Simplilearn 10 Best SEO Services Of 2024 Forbes Best web design software of 2024 TechRadar MERN Stack Explained: A Beginner's Guide [2025] Simplilearn 38 Web Development Stats You Should Know in 2024 Influencer Marketing Hub WordPress Script Isn't Working SitePoint Best laptops for programming of 2024 TechRadar Unlock Your Creativity: Building and Testing Websites in the Ubuntu Web Development Playground Linux Journal Top Web Design Trends in 2024 Netguru New Web Development Tool Pulls Design Tokens From Figma The New Stack Is_dir across drive from C: to D SitePoint CSS prevents page scrolling SitePoint Top 10 Front End Languages - A Beginner's Guide Simplilearn B2B Website Development Cost (2024) DesignRush 35 Best Web Design Companies 2024 Built In 10 Chicago Web Design and Development Agencies You Should Know Built In Chicago |
RELATED ARTICLES
Make Your Own Website - General Website Design Tips Wow, we`ve already taken a domain and chosen a web host. Great job ! Now it`s time for something special: making your own website. Where on Earth is Your Websitee? You've just finished congratulating your marketing team. After six months of concentrated effort you can now actually find your own company web site within the search engines. Building a Great Intranet Taxonomy While it may seem like a "quick and easy" task, defining the navigation structure and organization of your intranet site will be one of the most challenging tasks you will face in the course of your project. It is also one of the most critical success factors. Increase Your Affiliate Earnings with a Smart Webmaster Plan Affiliate programs are a great way to earn an income online in a few easy steps. However, if you don't have a plan you are going to fail. Functions and Subroutines in ASP Functions and Subroutines in ASP If you read our Tutorial on Include Files (SSI) then you learned how to encapsulate ASP code within include files and the benefits it brings us. As developers, we should endeavour to make our lives easier wherever possible. Five Question-Five Minute Web Makeover Quiz If you haven't made the sales and built your clients to an income you want, then you may need a Web Site makeover.What I mean by that is, most people contact a web master to put up their site. Launch Your Own Website Today - Its Easier Than You Think! Thousands of people are now making a living online and the opportunities are abundant as the Internet continues its growth. An added benefit of running an Internet business is that you can usually start one part-time while you maintain your job and steady income. 7 Questions to Understand Your Customer Better Customer service questionnaires can help your clients better understand their requirements. Your clients can benefit by:* Focusing on immediate project requirements* Increased awareness of budgeted time and finances* Better understanding of project goals* Setting priorities of essential project features* Planning for project post-implementation phaseOn the other hand, you as a service provider will have a clearer understanding of what your clients want. Guidelines for Web Page Optimization Below, I have listed 8 simple steps that you can take to optimize your web pages. By following these, you will improve your chances of increasing your rankings:1) Target one word for each page: A huge mistake that many beginners make is cramming numerous keywords onto every page. PHP & Account Activation When a user signs up at your website, you may want to verify their email address so you aren't getting bogus accounts in your database. A few lines of code can send an email to the address specified, containing a welcome greeting and link to activate their account. Remember This When Building A New Site - Beginners Guide I recently helped my mom to launch a website (www.mom2me. Be Creative Before You Purchase Or Create A Website Before you jump into spending coutnless hours on designing and publishing your website, or spending hundreds on having it done by anyone else you should plan out your full design (or structure). This is very important so that when it comes time to do this long-lasting project you will be well prepared. Website Success is Key The popular search engine Google indexes over 8 billion websites. Is one of them yours, or is your website just floating around in cyberspace and you're hoping your customers will just find you? Is your website a benefit to your organization or company? Is it just an expensive showpiece or is it of true value?These are some of the many questions that can be asked when launching a new website. The Secret Benefit Of Accessibility: Part 1 - Increased Usability Web accessibility has so many benefits that I really do wonder why such a large number of websites have such diabolically bad accessibility. One of the main benefits is increased usability, which according to usability guru, Jakob Nielson, can increase the sales/conversion rate of a website by 100% and traffic by 150%. Have You Got Your Ear To The Ground Or Your Head In The Sand? What happened on your website yesterday? What about last week or last month? How about in the past hour? How many visitors come to your website as a result of using a search engine? How long do people stay on your website for on average? Which pages do your visitors go to?If you don't know the answer to some or all of these questions you are effectively operating a website blind.This is like riding a bike blindfolded and expecting to arrive at the right destination. Successful Web Development: 10 Key Elements There are many elements that are key to successful web development. There is no arguing that elements of talent such as graphic design, writing, and technical expertise are important. Flash Deadly Sins (That Can Kill Your Web Business) Looks like every client wants a Flash site these days but the reality is.. For Newer Sites, Web Marketing Depends On Titles & Links! We all start out the same. Some have budgets, some don't. The Cost Of A Web Site Just starting out, you can start with a simple informational site, which is all most need initially, and build up to a fuller site (e-commerce and/or interactive) when you can afford it.Your goal should be to get an online presence. How Disabled Users Access The Internet In 1995 a new era of accessibility for disabled people began. The Disability Discrimination Act was passed, stating that:"It is unlawful for a service provider to discriminate against a disabled person by refusing to provide any service which it provides to members of the public. |
home | site map |
© 2006 |