2

我有一个 android 应用程序,它有这个 css 作为正文背景:

html, body {
height:100%
margin: 0;
padding: 0;
color: white;
position: static;
text-align:left;
background: URL(images/aVia_Background_new.png) top center black;
background-repeat:no-repeat;
background-size: cover;
background-attachment:fixed !important;
}

当页面足够长可以滚动时,当页面向下遍历时,背景将直接滚动到屏幕外。它的作用就好像 background-attachment 属性设置为滚动,但它肯定不是。当在我的桌面上的谷歌浏览器中查看该网站时,背景工作正常,但由于某种原因,当它通过 Phonegap 翻译到 Android 时,它不能正常工作。这是 Phonegap 的已知问题吗?有谁知道我可以尝试解决这个问题吗?感谢任何回复。想法越多越好。

4

1 回答 1

1

是的..问题出在您的`背景附件:已修复;据我所知 position:fixed 不能正常工作。当我试图在我的应用程序中做一个固定的页眉/页脚时,我遇到了同样的问题。最后使用了 iScroll

于 2012-08-18T06:35:28.673 回答