-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
160 lines (146 loc) · 2.81 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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
<!doctype html>
<html>
<head>
<title>QuizzleStick</title>
<link rel="stylesheet" type="text/css" href="quizzlestick.css" />
<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/1.10.2/jquery.js"></script>
<script src="quizzlestick.js"></script>
</head>
<body>
<h1>Quickfire</h1>
<div class="quickfire"></div>
<h1>Multiple questions</h1>
<div class="multiple"></div>
<h1>Timed</h1>
<div class="timed"></div>
<h1>Multiple results</h1>
<div class="multiple-results"></div>
<script>
$( '.quickfire' ).quizzlestick( {
description: 'Quickfire quizzes!',
templates: {
answer: '\
<li class="quizzlestick-answer">\
<a href="#">{{answer}}</a>\
{{helpers.answerwidth}}%\
</li>\
'
},
questions: [
{
question: 'Who is older?',
answers: [
{
answer: 'Gerrard',
total: 300
},
{
answer: 'Owen',
correct: true,
total: 1000
}
]
}
]
} );
$( '.timed' ).quizzlestick( {
description: 'Timed quiz with automatic advancement',
timelimit: 30000,
nextdelay: 500,
results: 'You scored {{state.points}} out of {{state.maxpoints}} in {{helpers.time}}',
questions: [
{
question: 'Who is older?',
answers: [
{
answer: 'Pointy haired boss'
},
{
answer: 'Aguerro'
},
{
answer: 'Vivaldi',
correct: true
}
]
},
{
question: 'Who is older?',
answers: [
{
answer: 'Liz'
},
{
answer: 'Rob',
correct: true
},
]
},
{
question: 'Who is older?',
answers: [
{
answer: 'Barney',
correct: true
},
{
answer: 'Jeff'
},
]
}
]
} );
$( '.multiple-results' ).quizzlestick( {
results: [
{ points: 1, template: '<p>Maybe your shouldve paid attention in history</p>' },
{ points: 2, template: '<p>Not too shabby</p>' },
{ points: 3, template: '<p>Smarty pantaloons!</p>' }
],
questions: [
{
question: '<p>Who is older?</p>',
answers: [
{
answer: 'Pointy haired boss',
total: 100
},
{
answer: 'Aguerro',
total: 300
},
{
answer: 'Vivaldi',
correct: true,
total: 1000
}
]
},
{
question: '<p>Who is older?</p>',
answers: [
{
answer: 'Liz'
},
{
answer: 'Rob',
correct: true
},
]
},
{
question: '<p>Who is older?</p>',
answers: [
{
answer: 'Barney',
correct: true
},
{
answer: 'Jeff'
},
]
}
]
} );
</script>
</body>
</html>