jquery - How to stop scrollIntoView? -
i using jquery plugin jquery.scrollintoview
.
when click id(#back
, #forward
), plug-in works properly.
but, if click same id, want stop scroll event.
what should use? .stop()
? .stoppropgation()
?
i tried did not work...
var _doc = document; var notify = function() { // ... }; $(function() { $(_doc.getelementbyid('back')).click(function(){ $(_doc.getelementbyid('top')).scrollintoview({ duration: 3000, easing: 'easeoutquint', complete: notify }); }); $(_doc.getelementbyid('forward')).click(function(){ $('p:last').scrollintoview({ duration: 3000, easing: 'easeoutquint', complete: notify }); }); });
what should do?
Comments
Post a Comment