css - Firefox/IE CSS 问题 - 图像未按百分比缩放

标签 css internet-explorer firefox

我在本网站的主页上使用了第 3 方全屏 slider 。每张幻灯片中的图像设置为不大于 75% 宽度,它似乎在 Safari 和 Chrome 中有效,但在 IE (11) 或 Firefox 中无效。

知道这个是怎么回事吗?

http://www.communitychurchbunnell.com

最佳答案

设置你的宽度以使其与 IE 一起工作

#main-content #fullpage .section img, #main-content #fullpage .slide img {
  width: 100%;
  max-width: 75% !important;
}

此外,!important 不是必需的。

编辑

.fp-tableCell div 被设置为其中图像的宽度。 在文件 jquery.fullpage.min.js 中添加 max-width:100vh 来解决问题:

.fp-tableCell {
 display: table-cell;
 vertical-align: middle;
 width: 100%;
 height: 100%;
 max-width: 100vw;
}

关于css - Firefox/IE CSS 问题 - 图像未按百分比缩放,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27159531/

相关文章:

javascript - 将 json 文件中的图像显示到 HTML 文件中,但样式对它们不起作用

html - 将左侧 float div 中的图像与右侧 float div 中的文本垂直对齐

javascript - IE Scrollbar + Overflow Scroll + div on top of the

java - 如何使用 Selenium WebDriver 和 Java 选择单选按钮?

火狐壁虎 SDK : NPP_GetValue not getting called

java - 在 Smart GWT 中禁用浏览器拼写检查的正确方法?

javascript - 当鼠标放在 div 上时 jQuery 停止超时

css - 互联网浏览器 : Disable Access from Visitors

javascript - 当我在 google chrome 浏览器上运行我的本地 webRTC 应用程序时,没有生成 ICE 候选人

html - 如何在一行中在 div 内制作 2 个跨度,以便下一个 div 的内容不会转到第一个 div 的位置?