]> git.0d.be Git - panikweb.git/blob - panikweb_templates/templates/party.html
cancel party autoreload mode when leaving the party page
[panikweb.git] / panikweb_templates / templates / party.html
1 {% extends "base.html" %}
2 {% load thumbnails %}
3 {% load paniktags %}
4 {% load staticfiles %}
5 {% load i18n %}
6 {% block bodyID %}Party{% endblock %}
7 {% block title %}Party{% endblock %}
8
9 {% block extrascripts %}
10 <script>
11 var timer = null;
12 function reload() {
13   if (location.href.indexOf('/party') == -1) {
14     clearInterval(timer);
15     return;
16   }
17   if (location.href.indexOf('?') == -1) {
18     href = location.href;
19   } else {
20     href = location.href.substring(0, location.href.indexOf('?'));
21   }
22   href = href + '?' + new Date().getTime()
23   $('#Changing').fadeOut();
24
25   $('#Changing').load(href + " #Changing>*", null, function() {$('#Changing').fadeIn();});
26 }
27
28 $(function() {
29   timer = setInterval(reload, 10000);
30 });
31 </script>
32 {% endblock %}
33
34 {% block main %}
35
36 <div id="party" class="news">
37
38   <div class="content content-inline cf special">
39     <a class="block cf" href="{{ focus|get_focus_url}}">
40       {% if focus.content_category_title %}
41         <div class="label labels absolute">
42           <span class="item inBlock">{{ focus.content_category_title }}</span>
43         </div>
44       {% endif %}
45       <div class="logo">
46         <img class="normal" src="{{ focus.content_image|thumbnail:'500x375' }}"/>
47       </div>
48       <div class="title"><div>{{ focus.focus_title }}</div></div>
49     </a>
50   </div>
51
52   <style>
53 #metaNav, #Footer, .metas { display: none; }
54 .special .title {
55         opacity:0.9;
56         width: 482px;
57         background: black;
58         color: white;
59         position: absolute;
60         bottom: 0;
61         font-family: "RegloBold";
62         padding: 10px;
63 }
64
65 body {
66         height: 90%;
67         overflow: hidden;
68 }
69
70 #Changing,
71 #Commons {
72         float: none;
73         height: 200px;
74         width: 500px;
75         margin: 0 auto 0 auto;
76 }
77 #backgroundBox {
78         margin: auto 0;
79 }
80
81 #Commons > .wrapper {
82         position: relative;
83 }
84
85 #Player {
86         width: 200px;
87         position: absolute;
88         top: 50px;
89         left: 200px;
90 }
91
92   </style>
93
94 {% endblock %}