HTML正文在移动设备上未完全填满宽度 [英] HTML body not filling complete width on mobile devices
问题描述
如果我在常规浏览器中打开(GWT)页面,则一切正常.主体占据整个宽度,内容很好地居中.但是,如果我在手机上尝试此操作,主体不会占据整个宽度,因此内容不会居中.
If I open my (GWT) page in a normal browser, everything works fine. The body takes the whole width and the content is nicely centered. But if I try this on a mobile phone, the body does not take the whole width and therefore the content is not centered.
我不知道为什么会这样显示.此外,向body和html标签添加100%的宽度不能解决问题.
I couldn't find out why it is being displayed like this. Also, adding 100% width to body and html tag does not solve the issue .
有没有办法使它在移动设备上正常工作?
Is there a way to get this working nicely on a mobile device?
可以在以下页面访问该页面: http://www.vegantastic.de/
The page can be reached under: http://www.vegantastic.de/
推荐答案
这使我发疯,我只是通过在身体上添加 position:fixed
来解决它
this was driving me crazy and i just solved it by adding position:fixed
to the body
这篇关于HTML正文在移动设备上未完全填满宽度的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!