-
Notifications
You must be signed in to change notification settings - Fork 2
/
index.html
114 lines (95 loc) · 3.83 KB
/
index.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
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
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<title>网页标题</title>
<meta name="description" content="" />
<meta name="keywords" content="" />
<meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=0">
<meta name="format-detection" content="telephone=no">
<style type="text/css">
html, body, form, fieldset, p, div, h1, h2, h3, h4, h5, h6 {
-webkit-text-size-adjust: none;
}
html,body{height: 100%;padding: 0;margin: 0;}
.wrap{position: relative;width: 100%;height: 100%;overflow: hidden;}
.item{position: absolute;left:0;top:0;width: 100%;height: 100%;overflow: hidden;}
.item img{width: 100%;}
.item-0{background: #f44;-webkit-transition:all 0.4s;}
.item-1{background: #ccc;}
.item-2{background: #f96;}
.item-0.play{background: #666;}
#demo1{display: none;}
#loading{opacity:0;position: absolute;width: 200px;height: 10px;background: #f5ce13;margin: -10px 0 0 -100px;top:50%;left:50%;border-radius:5px;overflow: hidden;-webkit-transition:opacity 0.5s;}
#loading div{float: left;height: 10px;background: #5cb531;width: 0;-webkit-transition:width 1s;border-radius:5px;}
</style>
</head>
<body>
<div id="loading"><div></div></div>
<div class="wrap">
<div id="demo1">
<div class="item-0">
<img src="http://imgcache.gtimg.cn/mediastyle/mobile/event/20141118_ten_jason/img/open_cover.jpg?max_age=2592000" alt="" title="" />
</div>
<div class="item-1">
<img src="http://imgcache.gtimg.cn/mediastyle/mobile/event/20141118_ten_jason/img/im_cover.jpg?max_age=2592000" alt="" title="" />
</div>
<div class="item-2">
<img src="http://imgcache.gtimg.cn/mediastyle/mobile/event/20141118_ten_jason/img/bg1.jpg?max_age=2592000" alt="" title="" />
</div>
<div class="item-3">
<img src="http://imgcache.gtimg.cn/mediastyle/mobile/event/20141118_ten_jason/img/bg2.jpg?max_age=2592000" alt="" title="" />
</div>
<div class="item-4">
<img src="http://imgcache.gtimg.cn/mediastyle/mobile/event/20141118_ten_jason/img/bg3.jpg?max_age=2592000" alt="" title="" />
</div>
<div class="item-5">
<img src="http://imgcache.gtimg.cn/mediastyle/mobile/event/20141118_ten_jason/img/bg4.jpg?max_age=2592000" alt="" title="" />
</div>
</div>
</div>
<!-- debug start -->
<style type="text/css">
#debug-box{position: fixed;z-index:100;bottom:40px;right:0;height:260px;width:160px;padding: 3px;white-space: break-word;word-break:break-all;-webkit-overflow-scrolling: touch;overflow: auto;color: #ccc;background: rgba(0,0,0,0.5)}
</style>
<div id="debug-box"></div>
<script type="text/javascript">
log.i=0;
function log(str,clear) {
var box= document.getElementById('debug-box');
if (box) {
if (clear) {
box.innerHTML='';
}
box.innerHTML=log.i+': '+str+'<br>'+box.innerHTML;
log.i++;
}
}
window.onerror=function (e,l,n) {
log(e+' '+l+' '+n)
}
</script>
<!-- debug end -->
<script type="text/javascript" src="slidepage.js"></script>
<script type="text/javascript">
document.getElementById('loading').style.opacity=1
slidepage.init({
container:'#demo1',
onSlide:function () {
console.info(this.index)
},
loadingId:'#loading',
loadingImgs:[
'http://imgcache.gtimg.cn/mediastyle/mobile/event/20141118_ten_jason/img/open_cover.jpg?max_age=2592000',
'http://imgcache.gtimg.cn/mediastyle/mobile/event/20141118_ten_jason/img/im_cover.jpg?max_age=2592000',
'http://imgcache.gtimg.cn/mediastyle/mobile/event/20141118_ten_jason/img/bg1.jpg?max_age=2592000',
'http://imgcache.gtimg.cn/mediastyle/mobile/event/20141118_ten_jason/img/bg2.jpg?max_age=2592000'
],
preLoadingImgs:[],
onLoading:function (complete,total) {
this.$('#loading div').style.width=complete/total*100+'%';
}
});
</script>
</body>
</html>