![]() |
|||||||||||||||||
|
What are Cascading Style Sheets?HTML enables a Web page designer to have some degree of control over the look of a page but due to the basic nature of HTML this control is, and should be, limited.HTML was originally designed to be a platform-independent language for displaying documents. The idea is that any machine from a graphical browser to a sound or Braille browser should be able to interpret the document in the way best suited to the user. This causes problems for a graphic designer who wants to impose their look on the document or a web designer who wants to include complex interactivity or animation. How can a Braille browser attempt to display an animation? Attempts to increase the layout and functional capabilities of HTML have had mixed success. A confusing range of new HTML elements and attributes have been proposed, and in some cases implemented. For instance many people currently use the <FONT> tag to force a browser to display a particular font in a particular colour and at a particular size. The HTML below shows how this is done: <FONT FACE="Arial" COLOR="Green" SIZE="6">This text is large and green and its typeface is Arial</FONT>Of course the text will only appear in Arial if that font is installed on the computer that is displaying the page. Using the approach above the content of the page is mixed with information on how the content should be displayed. Although this works perfectly well it does not fit in with current ideas on how the Web should develop. Don't worry, you don't need to remove any <FONT> tags from your pages - they will work perfectly well for a good time to come. However, there is another way of doing things that will be clearer and more powerful in the long run. Purists complain that the original point of HTML is being lost. How is a Braille browser supposed to display text in a color? As far as a Braille browser is concerned, the extra information is useless. On the other hand, those who want a more graphical approach complain that the existing elements do not do enough. There are many properties that cannot be changed and changing the graphical style of many pages is time consuming. In order to satisfy both factions a way was needed to separate the content contained in a page of HTML from information on how the content should be displayed. Since 1995 the idea of using style sheets to contain rendering information has been discussed. The World Wide Web Consortium who attempt to define and guide Web development produced a working recommendation of how Cascading Style Sheets should be implemented. CSS was born and the makers of browsers began to support its use. >>> More... © 2003 Ashley Preston |
||||||||||||||||
![]() |
|||||||||||||||||