Sunday, January 29, 2012

Cascading Style Sheets

Cascading Style Sheets (CSS) provide a means for web authors to separate the appearance of web pages
from the content of web pages. This means that the content of the web site should go into your HTML files
(or XHTML files or JSP pages), but these files should not describe how that information is displayed.
Information about how the pages should appear goes into CSS files. The styles from this file that is given a
.css extension are then applied server-side.


In addition to being in external.css files, style sheets can also be placed internally in the <head>  element of 
the content file.  

A simple example is shown here: 

body { 
{font-family: arial, Helvetica, sans-serif; 
font-size: 1em; 
text-align: justify} 

h1 
{font-family: arial, sans-serif; 
font-size: em} 

{font-family: Courier New, sans-serif; 
font-size: 1em} 

 .note 
{background-color: #003333; 

No comments: