Knowledge Base Navigation

Articles: 51 Categories: 8

KB Article: Imported Style Sheets

Article:Imported Style Sheets     Popular
Submitted By:Taut
Date Added:04-27-2004 5:29:41
Hits:7,084



What is imported Style Sheet?

Imported Style Sheet is a sheet that can be imported to (combined with) another sheet. This allows creating one main sheet containing declarations that apply to the whole site and partial sheets containing declarations that apply to specific elements (or documents) that may require additional styling. By importing partial sheets to the main sheet a number of sources can be combined into one.

To import a style sheet or style sheets include the @import notation/s in the STYLE element. The @import notations must come before any other declaration. If more than one sheet is imported they will cascade in the order they are imported - the last imported sheet will override the next last; the next last will override the second last, and so on. If the imported style is in conflict with the rules declared in the main sheet then it will be overridden

Example:

<LINK REL=STYLESHEET HREF="main.css" TYPE="text/css">
<STYLE TYPE="text=css">
<!--
@import url(http://www.URL.com/main1.css);
@import url(http://www.URL.com/main2.css);
-->
</STYLE>

Current rating: 6.82 by 100 users
Please take one second and rate this article...

Not a Chance 12345678910 Absolutely

Please register or sign-in to post comments.


Jump to a selected article...