-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcarousel.html
More file actions
95 lines (82 loc) · 2.06 KB
/
carousel.html
File metadata and controls
95 lines (82 loc) · 2.06 KB
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Carousel</title>
<link rel="stylesheet" href="css/main.css">
<script
src="https://ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.min.js"></script>
<script src="js/slides.min.jquery.js"></script>
<script>
$(function() {
$('#slides').slides({
preload : true,
preloadImage : 'img/loading.gif',
play : 7000,
pause : 3500,
hoverPause : true,
animationStart : function(current) {
$('.caption').animate({
bottom : -35
}, 100);
if (window.console && console.log) {
// example return of current slide number
console.log('animationStart on slide: ', current);
}
;
},
animationComplete : function(current) {
$('.caption').animate({
bottom : 0
}, 200);
if (window.console && console.log) {
// example return of current slide number
console.log('animationComplete on slide: ', current);
}
;
},
slidesLoaded : function() {
$('.caption').animate({
bottom : 0
}, 200);
}
});
$('.pagination li a')
.css('background-image', 'url(img/pagination.png)');
});
</script>
</head>
<body>
<div id="slides">
<div class="slides_container">
<div class="slide">
<img src="img/slide-1.jpg" width="930" height="450" alt="Slide 1">
<div class="caption">
<p>Image 1</p>
</div>
</div>
<div class="slide">
<img src="img/slide-2.jpg" width="930" height="450" alt="Slide 2">
<div class="caption">
<p>Image 2</p>
</div>
</div>
<div class="slide">
<img src="img/slide-3.jpg" width="930" height="450" alt="Slide 3">
<div class="caption">
<p>Image 3</p>
</div>
</div>
<div class="slide">
<img src="img/slide.jpg" width="930" height="450" alt="Slide 3">
<div class="caption">
<p>Image 4</p>
</div>
</div>
</div>
<a href="#" class="prev"><img src="img/arrow-prev.png" width="24"
height="43" alt="Arrow Prev"></a> <a href="#" class="next"><img
src="img/arrow-next.png" width="24" height="43" alt="Arrow Next"></a>
</div>
</body>
</html>