IT Hardwares

eg: UK or Brides UK or Classical Art or Buy Music or Spirituality
 
eg: UK or Brides UK or Classical Art or Buy Music or Spirituality
 
Business & Money
Technology
Women
Health
Education
Family
Travel
Cars
Entertainment
Featured Sites
SD Editorials
Online Guide and article directory site.
Foodeditorials.com
Over 15,000 recipes & editorials on food.
Lyricadvisor.com
Get 100,000 Lyric & Albums.

Video on Include Files In Html

    View: 
Similar Videos
 
Youtube
How To Free Up Hard Drive Spac...
Youtube
Easy Duplicate Finder 2.2.2 Fu...
Include Files In Html
Heather Colman
"I have a template with my menubar and my banner on all my pages. I change the template and save it as the same template file that I used for creating all my pages. Is there a way I can apply that to all my pages instantly or do I have to make the changes manually for each page?"
The simple answer is to use an Include File. The difficult part may be to understand how to use them. Don't be intimidated by this however. Using an Include is not really that complex when you understand the basics of how they work and why.
A lot has been written about this subject. Most is rather technical and at best difficult to understand. This article will cover the basics of how an Include File works, in easy to understand language and explain how you can apply this technique saving yourself time and effort as a result.
What is an Include?
If you are familiar with basic html you know that whatever content you put in the html coding will be displayed through an open browser. The content is placed inside html tags on the same page you want to display.
An Include File contains content that is LOCATED SOMEWHERE ELSE instead of right there inside html tags of the page.
The contents of an Include file will also be dispayed through an open browser just as if the content were right there in the html code. That "somewhere else" is usually at a different location somewhere on your server.
Using specific php type language, the html code tells your browser to go to "anotherplace.html", grab the content and display part or all of it in your browser.
Why Use an Include File?
Why would you want to use an Include File when you can accomplish the same thing in your html coding?
There are a variety of reasons for this, but this one tops my list as the most beneficial.
For the sake of simplicity, lets assume you have a 100 page website and each one of those pages displays the same page header. Lets also assume you just had a beautiful new page header designed and you want it to replace your old one.
If you were use the traditional methods of updating your pages, you would be required to make changes to the html code on 100 pages. That's a lot of work. Even minor changes to that many pages takes time to accomplish.
By using an Include, you make the changes to the Include File, upload it to your server and it automatically updates those 100 pages for you.
The content inside an Include can be anything you can put on a webpage ie.. text, graphics, audio etc.
The format can be any format you use on your web page, ie.. .txt, .html, .asp, .php etc.
A small piece of php code (NOTE: Replace brackets [ ] with < > below)
[?php include('http://www.yourwebsite.com/yourpageheader.html'); ?]
replaces the standard code for your page header in your html code.
[img src="http://yourwebsite.com/yourpageheader.jpg"]
Now when you update your pages you can make changes to ONE file to update hundreds. The beauty of this is there are no limits to the number of Includes you can use on one page.
The Include File originated with the php language, but your pages do NOT need to be in php to use them.
To use an Include File in your html or htm pages you need to add a small .htaccess file to your server. If you do not already have .htaccess file on your server, you can make one in Notepad or any text editor. Starting with a blank page, copy and paste the following code.
#RemoveHandler .html .htm
#AddType application/x-httpd-php .php .htm .html
AddHandler application/x-httpd-php .html .htm
Save the file as .htaccess and upload it to the same folder that contains your index file. If you already have one, update it to include this information.
Next Paragraph..
A Guide to Business | Guide to Technology | Guide to Women | Guide to Health | Family Guide to | Travel & Vacations | Information on Cars

EditorialToday IT Hardwares has 2 sub sections. Such as Computer Guide and Hardware. With over 20,000 authors and writers, we are a well known online resource and editorial services site in United Kingdom, Canada & America . Here, we cover all the major topics from self help guide to A Guide to Business, Guide to Finance, Ideas for Marketing, Legal Guide, Lettre De Motivation, Guide to Insurance, Guide to Health, Guide to Medical, Military Service, Guide to Women, Pet Guide, Politics and Policy , Guide to Technology, The Travel Guide, Information on Cars, Entertainment Guide, Family Guide to, Hobbies and Interests, Quality Home Improvement, Arts & Humanities and many more.
About Editorial Today | Contact Us | Terms of Use | Submit an Article | Our Authors