iPad上的div垂直滚动条的问题 [英] Problems with div vertical scrollbars on iPad
问题描述
当用户在我的网站上执行搜索时,我想在一个带有垂直滚动条的小div中显示结果,而不是用户需要滚动整个页面。这在所有浏览器工作完美但我在iPad上遇到问题。我可以看到搜索结果不适合div,但没有滚动条显示在iPad上。此外,当我尝试在div内滚动,整个页面,而不是滚动。是否有解决方案可以使此工作?
When a user perform a search on my website I want to show the result in a small div with vertical scrollbars instead of that the user need to scroll the full page. That works perfect in all browsers BUT I get problems on the iPad. I can see that the search result doesn't fit into the div but no scroll bar is showing up on the iPad. Also when I try to scroll inside the div the full page is scrolled instead. Is there a solution to get this working?
HTML和CSS:
<div class="searchResult">
//Here I show the search result
</div>
div.searchResult
{
height: 540px;
overflow: -moz-scrollbars-vertical;
overflow-y: scroll;
}
推荐答案
你不能滚动,除非你使用双指法。但是,如果您查看最后一个链接,则有一个解决方法。
I believe the answer is that you cannot scroll unless you use the two-finger methods. However if you look at the last link, there is a workaround.
问题:
CSS Overflow属性在iPad中无法使用
http: //www.webmanwalking.org/library/experiments/dsp_frames_outer_document.html
解决方法:
http://cubiq.org/scrolling-div-on-iphone-ipod-touch
这篇关于iPad上的div垂直滚动条的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!