Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(window).scroll( function(){
- $('.fadeIn').each( function(i){
- var object = $(this).position().top + 35;
- var bottom_of_window = $(window).scrollTop() + $(window).height();
- if( bottom_of_window > object ){
- $(this).animate({'opacity':'1'},350);
- }
- });
- $('.fadeRight').each(function(i){
- var object = $(this).position().top + 15;
- var bottom_of_window = $(window).scrollTop() + $(window).height();
- if( bottom_of_window > object ){
- $(this).animate({
- 'opacity':'1'
- },350);
- }
- });
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement