I have a couple of html forms inside of an Android app.
为了在网上浏览中隐藏照片的背景形象,通过CSS将html网页的高度定在1000px(通过Java在网上浏览时也设定为100%,但并不总是奏效)。
Problem: Form A on page 1 is rather long, the submitbutton is at the end of the page. Form B on page 2 is short. After posting form A the app does not scroll to the top of page 2 but stays at the same position. As post B is short the user sees nothing but the empty background. Not good.
我们尝试了以下方法:
- pageUp (from the Java SDK)
- scrollTo() (from the Java SDK)
- insert a "
<a name="top"></a>
" in the html code of the forms and use"window.location.hash="top"
from within the app to address the anchor
最后一行几乎在任何地方,但并非在三星装置上运行(据报与三星S2和Ace被打破)。 我们是否还有其他选择?