最赞回答 / zhangcl
不是墨守成规,这能说明楼主还没有到大神级别属性选择器可以帮你解决很多复杂的样式问题,比如说:一个table有很多行,奇数行和偶数行要设置不同的样式,动态交互的时候要改变奇数行和偶数行的样式(如鼠标移动到奇数、偶数行上),这个时候,用属性选择器是很方便的。不然难道你每一行都设置一个样式吗?
2015-01-30
如果觉得这节内容介绍的不太清楚,请大家看看这篇文章:http://www.w3cplus.com/content/css3-multiple-backgrounds
2015-01-30
接上面一条评论在补允一点
如果需要使用background-size来控制背景图片大小,我也不建议这样缩写,因为目前在一些移动终端上使用缩写是解析不出来的,所以不建议缩写
如果需要使用background-size来控制背景图片大小,我也不建议这样缩写,因为目前在一些移动终端上使用缩写是解析不出来的,所以不建议缩写
2015-01-30
对于答案我来被允一下我自己的看法。如果仅从多背景上来考虑,那么不需要使用background-size来控制,下面这样其实就是对的
.demo {
background:url(http://static.mukewang.com/static/img/logo_index.png) no-repeat 0 0,
url(http://static.mukewang.com/static/img/logo_index.png) no-repeat 100% 100%;
}
.demo {
background:url(http://static.mukewang.com/static/img/logo_index.png) no-repeat 0 0,
url(http://static.mukewang.com/static/img/logo_index.png) no-repeat 100% 100%;
}
2015-01-30
<style type="text/css">
a[class^=column]{
background:red;
color:#fff;}
a[href$=doc]{
background:green;
color:#fff;}
a[title*=box]{
background:blue;
color:#fff;}
</style>
a[class^=column]{
background:red;
color:#fff;}
a[href$=doc]{
background:green;
color:#fff;}
a[title*=box]{
background:blue;
color:#fff;}
</style>
2015-01-30
#brand:target p{
background:orange;
color:#ffffff;
}
老报 赶紧再去学一下相关知识吧!我也是醉了,真不知道哪错了,求解
background:orange;
color:#ffffff;
}
老报 赶紧再去学一下相关知识吧!我也是醉了,真不知道哪错了,求解
2015-01-30
div:empty{
border:1px solid green;
}
我实在看不出来哪里错了,大神求指教,之前用的那个:not也是报一样的错
border:1px solid green;
}
我实在看不出来哪里错了,大神求指教,之前用的那个:not也是报一样的错
2015-01-30
我用的苹果机子,safari浏览器,好多课程都看不了运行结果,运行没有反应,别的课程是可以的!前面的阴影的课程也是看不了运行结果!
2015-01-30
这里的CSS3选择器虽然在css3样式里不兼容IE浏览器,但是可以在jq的选择器里兼容各浏览器
$('a:not([class*=co]').css({ 'background':'#f00', 'display':'block', 'width':'20px', 'height':'20px'});
$('a:empty').remove();
比如这个,甚至可以兼容到IE6
$('a:not([class*=co]').css({ 'background':'#f00', 'display':'block', 'width':'20px', 'height':'20px'});
$('a:empty').remove();
比如这个,甚至可以兼容到IE6
2015-01-30
.item img和.item .information下的transition: all .6s属性是多余的吧。只有.item上能激活动画。
2015-01-30
div span:hover{
-webkit-animation-name:around;
-webkit-animation-duration: 10s;
-webkit-animation-timing-function: ease;
-webkit-animation-delay: 1s;
-webkit-animation-iteration-count:infinite;
}
-webkit-animation-name:around;
-webkit-animation-duration: 10s;
-webkit-animation-timing-function: ease;
-webkit-animation-delay: 1s;
-webkit-animation-iteration-count:infinite;
}
2015-01-29