use if condition and change on scroll in jqurey?
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<script>
$(document).ready(function(){
var $w = $(window).scroll(function(){
if ( $w.scrollTop() > 1000 ) {
alert("hello");
} else {
// ...
}
});
});
</script>
Comments
Post a Comment