我最近发现媒体查询是一个工具,所以没有太多的经验(真的秒秒)。 我有一个#logo,使用宽度的7%的余裕,但将其更改为25px的规则由于某些原因而不起作用。有趣的是,特定媒体查询的其余部分工作正常,只是一个标识没有。可能是什么问题呢?为什么没有应用媒体查询规则之一?
@media (max-width: 1320px) and (min-width: 105.1px){
#wrapper {
width: 100%;
}
#logo {
width: 195px;
height: 96px;
position: relative;
max-width: 230px;
max-height: 110px;
min-width: 115px;
min-height: 96px;
border: thin solid #000000;
float: left;
margin-left: 25px;
margin-top: -1px;
background-repeat: no-repeat;
background: black;
}
}
#logo {
width: 195px;
height: 96px;
position: relative;
max-width: 230px;
max-height: 110px;
min-width: 115px;
min-height: 96px;
border: thin solid #000000;
float: left;
margin-left: 7%;
margin-top: -1px;
background-repeat: no-repeat;
background: black;
}
它可能你有一个css规则,它会在你的查询后重写它的某处。其中也可能有一个重要的标志。 – Jeff 2015-01-31 19:19:48
请至少添加您的相关css代码 – 2015-01-31 19:20:15
没有任何重要的标记。对,让我想办法在这里发布代码)) – Tony 2015-01-31 19:24:47