banner
Welcome to HTML.co.uk, the number one resource for all news, information, and happenings regarding HTML.

Updates: HTML.co.uk has just been relaunched. Subscribe to our RSS Feed to stay on top of HTML news and techniques.
Apr
29th

Detailed Guide to Building an External Style Sheet

Advantages and disadvantages of using the external style sheets
The finest things that cane be done using this Cascading Style Sheets is that it would help you to keep your site in consistent. The simplest way to keep the site in consistent is to import an External Style Sheet or link the site. If the same external style sheet is used for each and every page of the site, it is sure that all the fonts of the site will be same.

Advantages of using the External Style Sheets
At once you can control the feel and also the look of many documents.
If you work with a team of people to create a Website, especially the External sheets is very much useful. Several style rules is pretty difficult to bear in mind and if you might taken a printed style guide and it is tedious and inefficient to be continuously go on flipping through out in order to determine if at all a example text has to be written in 14 point courier and 10 point Arial font.
You can even create classes of more styles that can be used on with various HTML elements as well.
If you want your fonts to be more efficient, you can easily group it.
All of the grouping methods that are used in CSS also can be used in this External Style Sheets as well and also this even provides you more flexibility with on your pages.

Disadvantages of using External Style Sheets:
If these External style sheets are very large, the download time will be increased.
They can increase the proximity of the site if there are small numbers of font styles.
These External style sheets get larger pretty quickly as it’s very hard to tell whether and when a style is no longer in use as it is deleted when the page s shut down or closed.

Creating an External Style Sheet
These External style sheets are produced or generated with a related syntax to the document level style sheets. Though all of the things that you need to include are the declaration and selector the syntax for the rule is and it is just like the document
Selector (property: value ;}
This rue has to be saved into a text file along with the extension of .css. Actually this is not required, but having this habit is good. By using this, you will be able to immediately recognize your style sheets.
You can link the style sheet documents in 2 different ways.

Linking
to link a style sheet document, use the HTML tag

Importing
Within the document level of style sheet, you can import the style sheet and with this you can import any URL and continue the style attributes of the External Style Sheet even without losing any document.

Post a Comment