Professional Documents
Culture Documents
Web1-M1 (5:00-6:30)
Day 3
Introduction to CSS (Cascading Style Sheets)
HTML without CSS
The first web page address was August 6, 1991.
http://info.cern.ch/hypertext/WWW/TheProject.html.
Introduction to CSS (Cascading Style Sheets)
• COLOR
SELECTOR{ COLOR:RED;}
• BACKGROUNDCOLOR
SELECTOR{BACKGROUND-COLOR:BLUE;}
• TEXT ALIGN
SELECTOR{TEXT-ALIGN: CENTER;}
LEFT, RIGHT, JUSTIFY
CSS PROPERTY AND VALUE
FONTS
• FONT FAMILY
SELECTOR{ FONT-FAMILY:ARIAL;}
• FONT STYLE
SELECTOR{FONT-STYLE: NORMAL;}
ITALIC, oblique
• FONT SIZE
SELECTOR{FONT-SIZE: 24PX;}
• FONT WEIGHT
SELECTOR{FONT-WEIGHT:BOLDER;}
NORMAL, BOLD
3 Type of CSS in HTML
Inline Styles
• Inline styles are styles that are written directly in the tag in
the HTML document.
<!DOCTYPE html>
<html lang=en>
<head>
<Title> Inline styles </Title>
</head>
<body>
<h1 style="color:blue;">This is a Blue Heading</h1>
</body>
</html>