Web Design/Embedded CSS

Example 1

As you can see the style information is placed between the  &   tags, inside the   &   tags

The CSS code below should make the:
 * Background color = yellow
 * Text inside a  tag = green & a font size of 10 pixels
 * Text inside a  tag = blue

Type the code below into your favorite code editor and save the file as cssexample.html

Exercise 2 – Changing the font family and font style using CSS.

The CSS code below should make the:
 * Text within the  tag, appear as helvetica, impact, sans-serif font.
 * Text within the  tag, appear as italic.
 * Text within the  tag, appear as gill sans, new baskerville, sans-serif font.

Paste the code below into your code editor, create a new page called cssexample2.html

Exercise 3 – Changing the border and aligning the text using CSS.

The CSS code below should make the:
 * Background within the  tag, appear as pink.
 * Border around the  tag, appear as solid green.
 * Text within the  tag, aligned in the center.
 * Border around the  tag, to appear as dotted red.

Paste the code below into your code editor, create a new page called cssexample3.html

Exercise 4 – Changing the margin padding using CSS.

The CSS code below should make the:
 * The text within the  tag will have a left margin of 2cm.

Paste the code below into your code editor, create a new page called cssexample4.html

Exercise 5 – Changing the color of a Horizontal Rule using CSS.

The CSS code below should make the:
 * The hortizontal rule  tag will appear as blue (instead of grey).

Paste the code below into your code editor, create a new page called cssexample5.html