实例
Select and style all elements with class="intro":
.intro
{
background-color:yellow;
}
{
background-color:yellow;
}
定义和用法
The .class选择器是指定类的所有元素的样式。
Browser Support
所有主流浏览器都支持.class选择器

更多实例
实例
Style all <p> elements with class="hometown":
p.hometown
{
background-color:yellow;
}
{
background-color:yellow;
}
