gpt4 book ai didi

html - 最大宽度在 mozilla 和 IE 中不起作用

转载 作者:太空宇宙 更新时间:2023-11-04 15:33:37 25 4
gpt4 key购买 nike

图像仅在 chrome 中根据浏览器宽度缩放,但在 IE 和 Mozilla Firefox 中不起作用。thumb img 在所有浏览器中都有效,但只有 .play img max-width 无效这是我的HTML

<div class="contai">
<div> <img src="1.png" style="max-width:100%" /></div>
<div class="thumb">
<img src="2.jpg" />
<div class="play"> <img src="videoImagePlay.png" /></div>
</div>
</div>

CSS

    .contai{
width:100%;
}
.thumb{
border: 1px solid rgb(226, 226, 226);
position:relative; float:left; width:38%
}
.thumb img{
max-width:100%
}
.play{
position:absolute; top:30%; left:35%
}
.play img{
max-width:50%
}

最佳答案

播放 class right : 0

像这样

.play{     
position:absolute; top:30%; left:35%; right:0;
}

现场演示 http://jsfiddle.net/puS7u/

关于html - 最大宽度在 mozilla 和 IE 中不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11204310/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com