!
<h1></h1> <p> </p> <h1></h1> <p> </p> CSS
sample2.css
h1 h1 { color : blue ; } : ; { }
: 14 : : p { font-size: 14pt; } p { font-style: italic; } p { text-decoration: underline; } p { font-size: 14pt ; font-style: italic; text-decoration: underline; } { : ; : ; : ; }
h1 { font-style: italic; } p { font-style: italic; } h1, p { font-style: italic; } { } : ;
HTML style.css h1 { font-style: italic; } p { text-decoration: underline; } <html> <head> <title> </title> <link href= style.css rel= stylesheet type= text/css /> </head> <body> <h1> </h1> <p> </p> </body> </html> CSS
HTML <html> <head> <title> </title> <style type= text/css > h1 { font-style: italic; } p { text-decoration: underline; } </style> </head> <body> <h1> </h1> <p> </p> </body> </html>
<html> <head> <title> </title> </head> <body> <h1 style= font-style: italic; > </h1> <p style= text-decoration: underline; > </p> </body> </html>
!
<head> <style type="text/css"> h1 { color: red; } p { font-style: italic; } </style> </head> <body> <h1></h1> <p></p> <p></p> <p></p> </body>
!!
!! HTML! <p class= note ></p> CSS p.note { font-style: italic; }! CSS.note { font-style: italic; } (p) note note
HTML <p class= red ></p> p.red { color: red; } + CSS p.red { color: blue; } font <font color= red ></font> CSS
HTML <p class= red ></p> p.red { color: red; } + CSS <p class= remark ></p> p.red { color: blue; } CSS
<p class= note ></p> <ul> <li class= note ></li> <li></li> </ul> <body> <div id= header > </div> <div id= content ></div> <div id= footer ></div> </body>
!! HTML <h1 id= basic-html >HTML</h1> CSS h1#basic-html { color: navy; } #basic-html { color: navy; } id
HTML <p>web <span>1989</span> </p> span HTML <p>web <span class= year >1989</span> span class </p> CSS + span.year { font-style: italic; text-decoration: underline; }
HTML h1 p <h1>web</h1> <p>web1989</p> <p>w3c1994</p> HTML <div class= section > <h1>web</h1> <p>web1989</p> <p>w3c1994</p> </div> CSS div + div.section { border : dashed 2pt blue; }
[CSS ]