CSS选择器
来源:互联网 发布:h5场景源码 编辑:程序博客网 时间:2024/06/05 23:38
@charset "utf-8";
/*属性选择器*/
/*[href]
{
color:orange;
}
[type="password"]{
border:1px solid green;
}
*/
/*[href^="http:"]
{
color:orange;
}
[href$=".cn"]{
color:red;
}*/
/*[href*="bing"]{
color:green;
}*/
/*
具有多个值时,匹配其中一个值的*/
[class~="def"]{
background-color: black;
}
/*后代选择器*/
p b{
}
/*子选择器*/
ul>li{
}
/*相邻兄弟*/
p+b{
}
/*普通兄弟元素
p~b{
}*/
/*a::befor{
content:' click';
}*/
/*
div > p : only-of-type{
color:red;
}
ul > li :nth-child(2){
color:red;
}
div >p :nth-of-type(2){
color:red;
}
a:link{
}
a :visited{
}
a:hover{
}
a:active{
}
a:focus{
}
a:not([href*="baidu"]){
}
p:empty{
display: none;
}*/
p:lang(en){
background-color: red;
}
/*属性选择器*/
/*[href]
{
color:orange;
}
[type="password"]{
border:1px solid green;
}
*/
/*[href^="http:"]
{
color:orange;
}
[href$=".cn"]{
color:red;
}*/
/*[href*="bing"]{
color:green;
}*/
/*
具有多个值时,匹配其中一个值的*/
[class~="def"]{
background-color: black;
}
/*后代选择器*/
p b{
}
/*子选择器*/
ul>li{
}
/*相邻兄弟*/
p+b{
}
/*普通兄弟元素
p~b{
}*/
/*a::befor{
content:' click';
}*/
/*
div > p : only-of-type{
color:red;
}
ul > li :nth-child(2){
color:red;
}
div >p :nth-of-type(2){
color:red;
}
a:link{
}
a :visited{
}
a:hover{
}
a:active{
}
a:focus{
}
a:not([href*="baidu"]){
}
p:empty{
display: none;
}*/
p:lang(en){
background-color: red;
}
0 0
- CSS选择器,jQuery选择器
- jQuery选择器 CSS选择器
- css选择器-基本选择器
- css选择器-属性选择器
- CSS选择器选择器
- CSS选择器-属性选择器
- css选择器
- css选择器
- css选择器
- Css选择器!
- CSS选择器
- css选择器
- CSS选择器
- CSS选择器
- CSS选择器
- CSS选择器
- css选择器
- css选择器
- H3C交换机web管理配置
- Bootstrap之组件
- UIBezierPath 介绍
- 懒加载
- 复选框全选与复选框取值
- CSS选择器
- Mysql+PHP的事物处理用例
- html5学习笔记之编程软件
- HttpServletRequest 的各种方法的返回值
- suid,sgid,sticky_bit
- apache的Cordova,编译运行能通过,打包报file not find错误
- 一个介绍GPU历史以及各个参数具体意义的好网站
- 清除所有文本框的值
- Linux 文件权限