Difference between revisions of "Team:UCLA/Template/Javascript"

(Created page with "<html> <script type="text/javascript" src="http://code.jquery.com/jquery-1.8.0.min.js"></script> <!--SPIDER TOP BUTTON--> <script type="text/javascript"> jQuery(document).ready(f...")
 
 
Line 1: Line 1:
 
<html>
 
<html>
 
<script type="text/javascript" src="http://code.jquery.com/jquery-1.8.0.min.js"></script>
 
<script type="text/javascript" src="http://code.jquery.com/jquery-1.8.0.min.js"></script>
<!--SPIDER TOP BUTTON-->
 
<script type="text/javascript">
 
jQuery(document).ready(function($){
 
    $('.spiderbutton, .backtotop').click(function(){
 
          $('.spiderbutton').stop(true,true).animate({ top: '-=55%'}, 800, function(){$('.spiderbutton').stop(true,true).animate({ top: '+=55%'}, 3000)});
 
          $('.spiderline').stop(true,true).animate({ top: '-=55%'}, 800, function(){$('.spiderline').stop(true,true).animate({ top: '+=55%'}, 3000)});
 
          $("html, body").animate({ scrollTop: 0 }, 1000);
 
    });
 
});
 
</script>
 
  
  

Latest revision as of 00:00, 7 September 2015