Cascading Style Sheets -- Style Outside of HTML

The second, and most commonly used method is to put all of the style information into a separate document, designated by a .CSS file extension, which is linked to any number of documents using a <LINK> element in the <HEAD>. In such a case, only the selectors and declarations are contained within the style sheet document, and the <LINK> tag contains a REL attribute which defines it as a stylesheet, a HREF attribute whose value is the URL of the style sheet, and the style sheet's MIME type defined by a TYPE attribute. The style sheet that defines the styles used in this Tutorial web site can be seen here, and the tag which links this document to it looks like this:

<LINK REL="stylesheet" HREF="style.css" TYPE="text/css">

Style information can also be added to most elements as extended markup attributes without the presence of a style sheet. This method only works during the instance of the element which contains the style attribute and the declaration contained within a particular element only affects the text marked up by that specific element and no other text. The advantage of this is that style information can be added to a document which has already been styled by information in the head element, or linked using the <LINK> tag, which will supercede other style information on a one-time-only basis.