我刚得到这个主题并尝试导入文档中推荐大小的背景图像,但似乎有些奇怪 并且这些图像在主题 style.css 中存在 CSS 问题
这是我网站的链接 http://test.doublelift.kr
下面是实际模板的演示
http://www.cssvillain.com/hungry/
如果您调整窗口大小并看到图像文件缓慢缩小而不是根据 px 更改宽度,则问题很明显。
图像宽度是基于我得到的模板的百分比,所以我试图让它自动并根据原始模板的高度编写样式 但似乎它正在从其他地方读取样式 在 chrome 的开发者工具上没有成功
感谢你的帮助
最佳答案
#single-page-header {
height: 1000px !important;
overflow-y: visible !important;
}
.cycle-slideshow {
position: relative !important;
}
#single-pager-header .cycle-slideshow img {
display: block !important;
max-height: 1000px !important;
width: auto !important;
}
@media screen and (max-width: 1370px) and (min-width: 1025px) {
#single-page-header {
height: 720px !important;
}
#single-page-header .cycle-slideshow img {
max-height: 720px !important;
}
}
@media screen and (max-width: 1024px) {
.single-page-header-content {
overflow: hidden !important;
}
.single-page-header-content .cycle-slide-show {
overflow: hidden !important;
}
}
@media screen and (max-width: 1024px) and (min-width: 768px) {
#single-page-header .cycle-slideshow img {
max-height: 1000px;
}
}
@media screen and (max-width: 767px) {
#single-page-header {
height: 500px !important;
overflow: hidden !important;
}
}
@media screen and (min-width: 1025px) {
#single-page-header .cycle-slideshow img {
max-height: 1000px;
}
}
关于html - wordpress 主题中的幻灯片图像缩小?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45592486/