-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathVote.tpl
226 lines (216 loc) · 6.3 KB
/
Vote.tpl
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
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Karaoke Vote</title>
<!--[if lte IE 8]>
<script type="text/javascript" src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<link href="desktop.css" rel="stylesheet" type="text/css">
</head>
<style type="text/css">
@charset "utf-8";
/* CSS Document */
article, aside, figure, footer, header, nav, section {
display: block;
margin: 0;
padding: 0;
}
body {
font-family: "Myriad Pro";
color: #000;
background-color: #FFFFFF;
margin: 0px;
padding: 0px;
background-image: url(http://i.imgur.com/dWJvO.jpg);
background-repeat: repeat-x;
margin-top: 170px;
}
#container {
width: 550px;
padding-top: 10px;
margin-top: 10px;
margin-right: auto;
margin-bottom: 0px;
margin-left: 10px;
}
#logo h1, #logo h2 {
position: absolute;
top: -550px;
}
nav {
padding-top: 0px;
}
#maincontent {
margin-top: 10px;
padding-top: 10px;
padding-right: 0px;
padding-bottom: 10px;
padding-left: 0px;
}
ul {
padding:0;
margin:0;
}
nav ul {
list-style: none;
margin-bottom: 10px;
font-weight: bold;
font-size:15px;
}
nav ul li {
padding-right: 5px;
float: left;
}
nav ul a {
display: block;
width:60px;
padding: 5px;
text-align:center;
text-decoration: none;
color: #fff;
border: 1px solid #4874A1;
border-radius: 8px;
-moz-box-shadow: 1px 1px 3px rgba(0,0,0,0.3);
-webkit-box-shadow: 1px 1px 3px rgba(0,0,0,0.3);
box-shadow: 1px 1px 3px rgba(0,0,0,0.3);
text-shadow: 1px 1px 1px rgba(0,0,0,0.8);
height: 20px;
margin-top: -10px;
margin-right: 0px;
margin-bottom: 5px;
margin-left: 0px;
font-family: "Myriad Pro";
}
nav ul a:link, nav ul a:visited {
background: rgba(255,255,255,0.2);
}
nav ul a:hover, nav ul a:active, nav ul a:focus {
background: rgba(255,255,255,0.4);
}
nav ul li:hover {
margin-top:-10px;
}
nav ul li {
float: right;
-webkit-transition-duration:.5s;
-webkit-transition-property:margin-top;
-webkit-transition-timing-function:ease-in-out;
-o-transition-duration:.5s;
-o-transition-property:margin-top;
-o-transition-timing-function:ease-in-out;
-moz-transition-duration:.5s;
-moz-transition-property:margin-top;
-moz-transition-timing-function:ease-in-out;
transition-duration:.5s;
transition-property:margin-top;
transition-timing-function:ease-in-out;
}
.pod {
background: #fff;
padding: 10px;
width: 500px;
float:left;
margin-right: 0px;
margin-top: 10px;
margin-bottom: 10px;
margin-left: 0px;
border: 2px solid #4874A1;
margin: 5px 0px;
border-radius: 16px;
-moz-box-shadow: 1px 1px 3px rgba(0,0,0,0.3);
-webkit-box-shadow: 1px 1px 3px rgba(0,0,0,0.3);
box-shadow: 1px 1px 3px rgba(0,0,0,0.3);
opacity: 0.5;
filter: alpha(opacity=50);
-webkit-transition: opacity .3s linear;
-moz-transition: opacity .3s linear;
transition: opacity .3s linear;
}
.pod:hover {
opacity: 1;
filter: alpha(opacity=100);
-webkit-transition: opacity .3s linear;
-moz-transition: opacity .3s linear;
transition: opacity .3s linear;
}
.podContent {
margin-top:10px;
width: 120px;
height:90px;
overflow:hidden;
text-align: left;
float:left;
font-family: "Myriad Pro";
}
</style>
<script language="Javascript">
function buttonClicked(frm)
{
if(frm.query.value == "")
{
alert("Please input something or gtfo");
}
else
{
window.location = '/vote/{{content['session']}}?query='+ encodeURIComponent(frm.query.value);
}
}
</script>
</head>
<body>
<div id="container">
<div id = "headerinner" style="overflow:hidden;width: 550px; padding-top: 10px;">
<FORM>
<div style="float:left">
<INPUT TYPE="TEXT" NAME="query">
<INPUT TYPE="Button" Value="Search for a Video" onClick="buttonClicked(this.form)">
</div>
<div style="float:right">
<header id="logo">
<h1>Karaoke</h1>
<h2>Sustainable, organic and natural</h2>
<nav>
<ul>
<li><a href="/vote/{{content['session']}}">Vote</a></li>
<li><a href="/play/{{content['session']}}">Play</a></li>
</ul>
</nav>
</header>
</div>
</FORM>
</div>
<div id="maincontent">
% for vid in content['videos']:
<div id="inner" style="overflow:hidden;width: 2000px">
<section class="pod">
<figure class="podContent"><img src="{{vid["thumbnail_url"]}}" width="120" height="90" alt="specials"></figure>
<div class="podContent" id="info" style="width: 260px; margin-left:10px">
<p>{{vid["title"]}}</p>
<p>{{vid["vid_time"]}}</p>
</div>
<form action = "/vote/{{content['session']}}/{{vid['id']}}/+" method="post">
<div class="podContent" id="hide" style="width: 1px">
<input type="hidden" name="vid_url" value="{{vid["vid_url"]}}">
<input type="hidden" name="img_url" value="{{vid["thumbnail_url"]}}">
<input type="hidden" name="vid_title" value="{{vid["title"]}}">
<input type="hidden" name="vid_time" value="{{vid["vid_time"]}}">
</div>
<figure class="podContent" style="width:48px; height:70px; padding-top: -45px; text-align: right;">Score:<input type = "image" img src="http://i.imgur.com/4BXhS.png" width="48" height="48"/></figure>
</form>
<form action = "/vote/{{content['session']}}/{{vid['id']}}/-" method="post">
<div class="podContent" id="hide" style="width: 1px">
<input type="hidden" name="vid_url" value="{{vid["vid_url"]}}">
<input type="hidden" name="img_url" value="{{vid["thumbnail_url"]}}">
<input type="hidden" name="vid_title" value="{{vid["title"]}}">
<input type="hidden" name="vid_time" value="{{vid["vid_time"]}}">
</div>
<figure class="podContent" style="width: 48px; height:70px; margin-left:5px; padding-top: -30px;">{{vid["score"]}}<input type = "image" img src="http://i.imgur.com/bcpLc.png" width="48" height="48"/></figure>
</form>
</section>
</div>
%end
</div>
</div>
</body>
</html>