SiteExperts.com Logo Home | Community | Developer's Paradise | Jobs
User Groups | Site Tools | Site Information | Search
 Main Menu
 HTML Online
Introduction

Head Elements
  Meta-information
  Link Relationships
  Script and Style

Block Elements


Sponsored Links

Link Relationships

The <LINK> element is used to define relationships with other documents or types of documents. The most common use of the link element is to associate style sheets with the document. On InsideDHTML we share a single style sheet document throughout the entire web-site. This makes it possible to change the font or appearance of every page on the site by editing a single file. We associate this style sheet by including the following link element in the head of every page:

<LINK REL="stylesheet" href="/_res/css/tone.css" type="text/css">

The REL attribute defines the relationship between the current document and the referenced document. Another common relationship is to define the relationship of the current document to others. This is most useful when you are creating a sequence of pages. This relationship can be defined by creating link relationships to documents with the REL set to "next" or "prev". These relationships will have no effect on the rendering of your document. Instead, tools or your scripts can take advantage of this information to improve your visitor's experience. Currently Internet Explorer only uses the external style sheet relationship. However, In the book, Inside Dynamic HTML, Scott Isaacs covers how to write scripts that build navigation frames from these relationships. You can read the chapter containing this sample on-lineIE4 Only and run the sample demonstrated by the figure below:

The TYPE attribute defines the mime-type of the referenced document. When defining a relationship with an HTML document, the TYPE should be assigned "text/html".

Head Elements - Adding Style and Script...

Copyright © 1997-2008 InsideDHTML.com, LLC. All rights reserved.