Scroll event is not firing while scrolling the ul
. I'm using jQuery version 1.10.2. As I'm loading the ul
from an ajax page, I couldn't use $('ulId').on('scroll', function() {});
or other live methods. Please help me to find a solution.
$(document).on( 'scroll', '#ulId', function(){
console.log('Event Fired');
});
You probably forgot to give #
before id for id selector, you need to give #
before id
ie is ulId
You problably need to bind scroll event on div that contains the ul and scrolls. You need to bind the event with div instead of ul
$(document).on( 'scroll', '#idOfDivThatContainsULandScroll', function(){
console.log('Event Fired');
});