Jump to content
Search Community

Frans

Members
  • Posts

    4
  • Joined

  • Last visited

Frans's Achievements

0

Reputation

  1. Frans

    disable reverse

    Hello, i am new to superscrollorama. I want to disable an animation when you scroll up. I found the code on the website but it doesn't work for me: The 5th parameter is reverse, which you can use to disable reverse animation. controller.addTween('#fade', TweenMax.from($('#fade'),.5,{ css:{opacity:0}}), 200, false); // prevent backwards animation of the element What am i doing wrong? Frans
  2. Frans

    Noob needs help

    Ha Rodrigo, Thanks man i finally got it yea. I forget to add position: relative; , so stupid of me. Thanks for your help. Frans
  3. Frans

    Noob needs help

    Thanks for the quick reply Rhernando. But unfortunately it didn't work. I pasted your code but only 1 of the 2 images gets an animation. I tried placing them in different div's or giving them other names but nothing works. Can you please take a look at my code. Thanks, Frans My html is now: <!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> <title>SUPERSCROLLORAMA - Simple Demo #1</title> <link href='http://fonts.googleapis.com/css?family=Luckiest+Guy' rel='stylesheet' type='text/css'> <link rel="stylesheet" href="css/normalize.css" type="text/css"> <link rel="stylesheet" href="css/style.css" type="text/css"> </head> <body class="simple-demo" > <div id="content-wrapper"> <div id="examples-1"> <h2 id="fly-it"><img src="img/image1.png"></h2> <h2 id="fly-it2"><img src="img/image2.png"></h2> </div> </div> <script type="text/javascript" src="js/greensock/TweenMax.min.js"></script> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script> <script>window.jQuery || document.write('<script src="_/js/jquery-1.9.1.min.js"><\/script>')</script> <script src="js/jquery.superscrollorama.js"></script> <script> $(document).ready(function() { var controller = $.superscrollorama(); // individual element tween examples //This image will come from the left side of the screen controller.addTween('#fly-it', TweenMax.from( $('#fly-it'), .5, {left:1000, ease:Quad.easeInOut})); //This image will come from the right side of the screen controller.addTween('#fly-it2', TweenMax.from( $('#fly-it2'), .5, {left:-1000, ease:Quad.easeInOut})); }); </script> </body></html>
  4. Frans

    Noob needs help

    Hello, i am an absolute noob with javascript and superscrollorama. I am trying to fly in a few images when you scroll down the page. The first images needs to fly-in from the left and the 2nd from the right. It worked for 1 image but when i try to make other images fly-in non of them work (or only the first one). Please help me! html: <h2 id="fly-it"><img src="img/image1.png"></h2> <h2 id="fly-it2"><img src="img/image1.png"></h2> script: controller.addTween('#fly-it', TweenMax.from( $('#fly-it'), .5, {css:{right:'1000px'}, ease:Quad.easeInOut})); controller.addTween('#fly-it2', TweenMax.from( $('#fly-it2'), .5, {css:{left:'1000px'}, ease:Quad.easeInOut}));
×
×
  • Create New...