cascading style sheet basics:
Let's discuss the cascading style sheet basics
We are going to discuss the basics of stylesheet .so, let's discuss the basics. To create a cascading style sheet, you have to use the syntax to define the parameters of a style by first specifying the HTML element that you want to assign a style to and then, inside of curly braces{}, you list the attributes NAME and VALUE pair or pairs.
You have to separate each name and value with a colon like this: NAME: VALUE. Then you separate each NAME: VALUE; pair with a semicolon, even if there is only one pair, like this:
You have to separate each name and value with a colon like this: NAME: VALUE. Then you separate each NAME: VALUE; pair with a semicolon, even if there is only one pair, like this:
{NAME: VALUE ;}
{NAME: VALUE; NAME: VALUE; NAME: VALUE ;}
Here are three different examples of real NAME: VALUE; pair:
1. {color: red ;}
2. {text-align: left; float: right ;}
3. {background-color: purple; margin: 10pt; border-style:ridge;}
Putting all together, here is a simple style that causes all H2 element headings to be displayed with a font that is sized at 14 points and colored aqua:
H2 {font-size: 14pt; color:aqua;}
No comments:
Post a Comment