解决css样式被内置样式覆盖的问题
.preImg {
height:400px !important }
<img id="preImg" class="preImg" style="width:100px;height:70px;background-color:#ccc;border:1px solid #333"/>
以上代码即可保证id为preImg的图片高度为400px,而不会被其自身的style覆盖。
.preImg {
height:400px !important }
<img id="preImg" class="preImg" style="width:100px;height:70px;background-color:#ccc;border:1px solid #333"/>
以上代码即可保证id为preImg的图片高度为400px,而不会被其自身的style覆盖。