javascript - Infinite scrolling not working -


i trying implement infinite scrolling function seems code not working. can me?

    $(document).ready(function(){     var origelement = $('.scroll').clone();      if($(window).width() > 500){         $('.scroll').jscroll();         }      $(window).resize(function(){         if($(window).width() < 500){             alert($(window).width());            $('.scroll').remove();            $('#container').append(origelement);            }         else{              $('.scroll').jscroll();             }         }); }); 

bellow html code:

    <div id="container">     <div class="scroll">         <h3>page 1</h3>         <p>page 1 of jscroll example - jquery infinite scrolling plugin      content of page 1 in jscroll example. scroll bottom of box load next set of content.      example text jscroll demonstration. jscroll jquery plugin infinite scrolling, endless scrolling, lazy loading, auto-paging, or whatever may call it.      jscroll, can initialize scroller on element fixed height , overflow setting of "auto" or "scroll," or can set on standard block-level element within document , scrolling initialized based on brower window's scroll position.      jscroll open-source , can downloaded github repository @ github.com/pklauzinski/jscroll. </p>         <a href="www.google.bg">next page</a>     </div> </div> 

thanks

i trying run first example in jsfiddle seems not working: http://jscroll.com/


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -