Hi, all.
Do you have any idea how to implement an indefinite scroll widget like google reader on iGoogle, which loads data dynamically and the scroll bar is replaced with a pair of up and down arrows.
I have a html structure like this:
<div id="note_column">
<ul class="messages">
<li class="note">
....
</li>
.
.
.
</ul>
</div>
And I tried to make indefinite scroll work inside this div, doing something like this:
$(".messages).wrap("<div id='scrollbox'></div>");
$("#scrollbox").css({
'height': '50em',
'overflow': 'scroll',
'overflow-y': 'hidden'
}).scroll(function() {
// judge if this is a scroll-to-bottom
// load list items if it is so
});
However :( Hidding the vertical scroll bar seems to disable the scroll event handler.
What puzzles me most now is how to hide the scrollbar and keep the scroll event handled.
Please tell me what might be wrong with my implementation.
Thanks in advance.