【发布时间】:2013-09-27 16:09:12
【问题描述】:
我在http://eiglaw.com 上遇到了问题——iPhone 屏幕右侧显示了大约 25 像素宽的空白/边框。我在 stackoverflow 上研究了这个问题,这些帖子是相关的,但是当我尝试提供的各种解决方案时,我无法解决这个问题:
Responsive website on iPhone - unwanted white space on rotate from landscape to portrait
Website body background rendering a right white margin in iPhone Safari
White space on right side of header on zoom
我在 iPad 上遇到了类似的问题,但能够通过这个媒体查询解决它:
@media only screen
and (min-device-width : 768px)
and (max-device-width : 1024px)
/*and (orientation : landscape)*/ {
html,
body {
width:1000px;
}
}
我尝试了各种针对 html 和 body 元素的媒体查询,但都没有成功。我查看了整个 CSS 文件中的背景图像、边距、填充、溢出等问题,但我真的很难过。有没有人有什么建议?
非常感谢!
【问题讨论】:
标签: html iphone ios css removing-whitespace