/
test-page.html
56 lines (56 loc) · 1.39 KB
/
test-page.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Dynamic Carousel</title>
<style type="text/css">
#carousel {
position: absolute;
left: 0px;
top: 20px;
}
#ver {
position: absolute;
margin: 0px;
left: 0px;
top: 0px;
}
.buttons {
position: relative;
top: 110px;
}
</style>
<script type="text/javascript" src="http://code.jquery.com/jquery-1.7.2.min.js"></script>
<script type="text/javascript" src="dynamic-carousel.js"></script>
</head>
<body>
<div id="carousel"></div>
<p id="ver"></p>
<a href="#" id="leftButton" class="buttons"><<<<<._._._._._._._._._._._._._._._._...</a>
<a href="#" id="rightButton" class="buttons">..._._._._._._._._._._._._._._._._.>>>>></a>
<script type="text/javascript">
$(document).ready(function() {
car = new Carousel("car");
car.setVars({
count: 11,
width: 100,
height: 100,
distance: 5,
speed: 15,
visible: 5
});
car.create("#carousel", "div", "colorful");
car.animate();
$("#ver").html("v" + car.version);
});
$("#leftButton").click(function() {
car.moveLeft();
return false;
});
$("#rightButton").click(function() {
car.moveRight();
return false;
});
</script>
</body>
</html>