Skip to content

Commit 3874ace

Browse files
author
Sebastian Helzle
committed
Fixed ie8 bug.
1 parent 7b5d143 commit 3874ace

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

example-endless-scroll/index.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,8 @@ <h1>jQuery Wookmark Plug-in Example</h1>
9696
// Check if we're within 100 pixels of the bottom edge of the broser window.
9797
var winHeight = window.innerHeight ? window.innerHeight : $(window).height(); // iphone fix
9898
var closeToBottom = ($(window).scrollTop() + winHeight > $(document).height() - 100);
99-
if(closeToBottom) {
99+
100+
if (closeToBottom) {
100101
// Get the first then items from the grid, clone them, and add them to the bottom of the grid.
101102
var items = $('#tiles li'),
102103
firstTen = items.slice(0, 10);
@@ -110,7 +111,7 @@ <h1>jQuery Wookmark Plug-in Example</h1>
110111

111112
$(document).ready(new function() {
112113
// Capture scroll event.
113-
$(document).bind('scroll', onScroll);
114+
$(window).bind('scroll', onScroll);
114115

115116
// Call the layout function.
116117
handler = $('#tiles li');

0 commit comments

Comments
 (0)