您的位置:首页 > Web前端 > CSS

CSS伪类 选择器

2013-03-11 19:57 253 查看
一、伪类
:active/*被激活的元素*/
:focus/*拥有键盘输入焦点的元素*/

:hover/*鼠标悬浮在元素上方时*/

:link/*未被访问的链接*/

:visited/*已被访问的链接*/

:first-child/*元素的第一个子元素*/

:lang/*带有指定 lang 属性的元素*/


CSS执行顺序是:lvcha

link :hover :active :visited
a:link {color: #FF0000; text-decoration: none}

a:visited {color: #00FF00; text-decoration: none}
a:hover {color: #FF00FF; text-decoration: underline}
a:active {color: #0000FF; text-decoration: underline}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: