Team:Groningen/DesignTest
From 2012.igem.org
(Difference between revisions)
Line 64: | Line 64: | ||
</ul> | </ul> | ||
</div> | </div> | ||
+ | |||
<script type="text/javascript" src="http://jqueryrotate.googlecode.com/svn/trunk/jQueryRotate.js"></script> | <script type="text/javascript" src="http://jqueryrotate.googlecode.com/svn/trunk/jQueryRotate.js"></script> | ||
<img src="https://static.igem.org/mediawiki/2012/e/e4/Groningen2012_AD_20120802_WindmillArms.png" id="image"> | <img src="https://static.igem.org/mediawiki/2012/e/e4/Groningen2012_AD_20120802_WindmillArms.png" id="image"> | ||
- | < | + | <script> |
- | + | $("#go").click(function(){ | |
- | + | ||
$("#image").rotate({ | $("#image").rotate({ | ||
bind: | bind: | ||
Line 80: | Line 80: | ||
} | } | ||
} | } | ||
- | } | + | }); |
- | } | + | }); |
</script> | </script> | ||
Line 95: | Line 95: | ||
{{Template:SponsorsGroningen2012}} | {{Template:SponsorsGroningen2012}} | ||
+ | |||
+ | <html> | ||
+ | <head> | ||
+ | <script src="http://code.jquery.com/jquery-latest.js"></script> | ||
+ | </head> | ||
+ | <body> | ||
+ | <button id="go">» Run</button> | ||
+ | |||
+ | <div id="block">Hello!</div> | ||
+ | <script> | ||
+ | |||
+ | /* Using multiple unit types within one animation. */ | ||
+ | |||
+ | $("#go").click(function(){ | ||
+ | $("#block").animate({ | ||
+ | width: "70%", | ||
+ | opacity: 0.4, | ||
+ | marginLeft: "0.6in", | ||
+ | fontSize: "3em", | ||
+ | borderWidth: "10px" | ||
+ | }, 1500 ); | ||
+ | }); | ||
+ | </script> | ||
+ | |||
+ | <script type="text/javascript" src="http://jqueryrotate.googlecode.com/svn/trunk/jQueryRotate.js"></script> | ||
+ | <img src="https://static.igem.org/mediawiki/2012/e/e4/Groningen2012_AD_20120802_WindmillArms.png" id="image"> | ||
+ | |||
+ | <script> | ||
+ | $("#go").click(function(){ | ||
+ | $("#image").rotate({ | ||
+ | bind: | ||
+ | { | ||
+ | mouseover : function() { | ||
+ | $(this).rotate({animateTo:180}) | ||
+ | }, | ||
+ | mouseout : function() { | ||
+ | $(this).rotate({animateTo:0}) | ||
+ | } | ||
+ | } | ||
+ | }); | ||
+ | }); | ||
+ | </script> | ||
+ | </body> | ||
+ | </html> |
Revision as of 14:52, 9 August 2012