Team:HUST-China/Templates/banner.js

From 2012.igem.org

(Difference between revisions)
(Created page with "<html> <script type="text/javascript" src="/path/to/jquery-1.4.2.min.js"></script> <script type="text/javascript" src="/path/to/lib/jquery.jcarousel.min.js"></script> <link rel=...")
(Blanked the page)
 
Line 1: Line 1:
-
<html>
 
-
<script type="text/javascript" src="/path/to/jquery-1.4.2.min.js"></script>
 
-
<script type="text/javascript" src="/path/to/lib/jquery.jcarousel.min.js"></script>
 
-
<link rel="stylesheet" type="text/css" href="/path/to/skin/skin.css" />
 
-
<script type="text/javascript">
 
-
function mycarousel_initCallback(carousel)
 
-
{
 
-
    // Disable autoscrolling if the user clicks the prev or next button.
 
-
    carousel.buttonNext.bind('click', function() {
 
-
        carousel.startAuto(0);
 
-
    });
 
-
 
-
    carousel.buttonPrev.bind('click', function() {
 
-
        carousel.startAuto(0);
 
-
    });
 
-
 
-
    // Pause autoscrolling if the user moves with the cursor over the clip.
 
-
    carousel.clip.hover(function() {
 
-
        carousel.stopAuto();
 
-
    }, function() {
 
-
        carousel.startAuto();
 
-
    });
 
-
};
 
-
 
-
jQuery(document).ready(function() {
 
-
    jQuery('#mycarousel').jcarousel({
 
-
        auto: 2,
 
-
        wrap: 'last',
 
-
        initCallback: mycarousel_initCallback
 
-
    });
 
-
});
 
-
</script>
 
-
 
-
 
-
</html>
 

Latest revision as of 06:08, 26 September 2012