Team:UCLA/anuved verma ucla2014 workspace/Javascript
From 2014.igem.org
(Difference between revisions)
Anuvedverma (Talk | contribs) |
Anuvedverma (Talk | contribs) |
||
Line 43: | Line 43: | ||
<!--MAIN PAGE BOXES--> | <!--MAIN PAGE BOXES--> | ||
<script type="text/javascript"> | <script type="text/javascript"> | ||
- | $(document).ready(function(){ | + | $(document).ready(function() { |
- | + | $('#box5').hover(function(){ | |
- | + | var smallTop = $('#box5').height() - $(".cover", this).height() -10 +"px"; | |
- | + | $(".cover", this).stop().animate({top:smallTop},{queue:false,duration:160}); | |
- | + | }, function() { | |
+ | $(".cover", this).stop().animate({top:'340px'},{queue:false,duration:160}); | ||
}); | }); | ||
- | + | $('#box6').hover(function(){ | |
- | + | var smallTop = $('#box6').height() - $(".cover", this).height() -10 +"px"; | |
- | + | $(".cover", this).stop().animate({top:smallTop},{queue:false,duration:160}); | |
- | + | }, function() { | |
+ | $(".cover", this).stop().animate({top:'340px'},{queue:false,duration:160}); | ||
}); | }); | ||
- | }); | + | $('#box7').hover(function(){ |
+ | var smallTop = $('#box7').height() - $(".cover", this).height() -10 +"px"; | ||
+ | $(".cover", this).stop().animate({top:smallTop},{queue:false,duration:160}); | ||
+ | }, function() { | ||
+ | $(".cover", this).stop().animate({top:'340px'},{queue:false,duration:160}); | ||
+ | }); | ||
+ | }); | ||
</script> | </script> | ||
Revision as of 23:58, 18 September 2014