summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rwxr-xr-xincludes/layout.php2
-rwxr-xr-xpages/poll.php22
-rwxr-xr-xtheme/layouts/4.5/layout.tpl6
-rwxr-xr-xtheme/layouts/6.2/layout.tpl6
-rwxr-xr-xtheme/layouts/7/layout.tpl6
-rwxr-xr-xtheme/layouts/subtle/layout.tpl6
-rwxr-xr-xtheme/pollIndex.tpl14
7 files changed, 1 insertions, 61 deletions
diff --git a/includes/layout.php b/includes/layout.php index 24d8a30..9e94b69 100755 --- a/includes/layout.php +++ b/includes/layout.php
@@ -51,8 +51,6 @@ if (isset($hatNav) && is_array($hatNav))
51 } 51 }
52} 52}
53 53
54$template->add('POTW', getPollOfTheWeek());
55
56$gethits = "SELECT * FROM config WHERE name = \"hits\""; 54$gethits = "SELECT * FROM config WHERE name = \"hits\"";
57$gethits2 = mysql_query($gethits); 55$gethits2 = mysql_query($gethits);
58$gethits3 = mysql_fetch_array($gethits2); 56$gethits3 = mysql_fetch_array($gethits2);
diff --git a/pages/poll.php b/pages/poll.php index e228712..c7cc909 100755 --- a/pages/poll.php +++ b/pages/poll.php
@@ -28,14 +28,7 @@ if (!isset($_GET['id']))
28{ 28{
29 $template = new FITemplate('pollIndex'); 29 $template = new FITemplate('pollIndex');
30 30
31 if (isset($_GET['start'])) 31 $getpolls = "SELECT * FROM polloftheweek ORDER BY id DESC";
32 {
33 $start = $_GET['start'] * 10;
34 } else {
35 $start = 0;
36 }
37
38 $getpolls = "SELECT * FROM polloftheweek ORDER BY id DESC LIMIT " . $start . ",10";
39 $getpolls2 = mysql_query($getpolls); 32 $getpolls2 = mysql_query($getpolls);
40 $i=0; 33 $i=0;
41 while ($getpolls3[$i] = mysql_fetch_array($getpolls2)) 34 while ($getpolls3[$i] = mysql_fetch_array($getpolls2))
@@ -59,18 +52,6 @@ if (!isset($_GET['id']))
59 $i++; 52 $i++;
60 } 53 }
61 54
62 if ($i==0)
63 {
64 generateError('404');
65 exit;
66 }
67
68 $start /= 10;
69 if ($start > 0)
70 {
71 $template->adds_block('PREVIOUS', array('ID' => ($start-1)));
72 }
73
74 $cntpolls = "SELECT COUNT(*) FROM polloftheweek"; 55 $cntpolls = "SELECT COUNT(*) FROM polloftheweek";
75 $cntpolls2 = mysql_query($cntpolls); 56 $cntpolls2 = mysql_query($cntpolls);
76 $cntpolls3 = mysql_fetch_array($cntpolls2); 57 $cntpolls3 = mysql_fetch_array($cntpolls2);
@@ -79,7 +60,6 @@ if (!isset($_GET['id']))
79 $template->adds_block('NEXT', array('ID' => ($start+1))); 60 $template->adds_block('NEXT', array('ID' => ($start+1)));
80 } 61 }
81 62
82 $template->add('POTW', getPollOfTheWeek());
83 $template->display(); 63 $template->display();
84} else { 64} else {
85 $template = new FITemplate('poll'); 65 $template = new FITemplate('poll');
diff --git a/theme/layouts/4.5/layout.tpl b/theme/layouts/4.5/layout.tpl index ada39b9..27abd83 100755 --- a/theme/layouts/4.5/layout.tpl +++ b/theme/layouts/4.5/layout.tpl
@@ -98,12 +98,6 @@ AudioPlayer.setup("http://fourisland.com/theme/js/audio-player/player.swf", {
98 98
99 <!--EXTRASIDEBAR--> 99 <!--EXTRASIDEBAR-->
100 100
101 <div class="module rounded sidebar">
102 <h3>Poll of the Week</h3>
103
104 <!--POTW-->
105 </div>
106
107 <P /> 101 <P />
108 102
109 <DIV class="sidebar module rounded"> 103 <DIV class="sidebar module rounded">
diff --git a/theme/layouts/6.2/layout.tpl b/theme/layouts/6.2/layout.tpl index 6f91eab..6ba1d1e 100755 --- a/theme/layouts/6.2/layout.tpl +++ b/theme/layouts/6.2/layout.tpl
@@ -138,12 +138,6 @@ AudioPlayer.setup("http://fourisland.com/theme/js/audio-player/player.swf", {
138 <!--END CREATE_HATNAV--> 138 <!--END CREATE_HATNAV-->
139 139
140 <!--EXTRASIDEBAR--> 140 <!--EXTRASIDEBAR-->
141
142 <div class="module rounded sidebar">
143 <h3>Poll of the Week</h3>
144
145 <!--POTW-->
146 </div>
147 141
148 <P /> 142 <P />
149 143
diff --git a/theme/layouts/7/layout.tpl b/theme/layouts/7/layout.tpl index 25489d7..2cacae5 100755 --- a/theme/layouts/7/layout.tpl +++ b/theme/layouts/7/layout.tpl
@@ -66,12 +66,6 @@ AudioPlayer.setup("http://fourisland.com/theme/js/audio-player/player.swf", {
66 <!--EXTRASIDEBAR--> 66 <!--EXTRASIDEBAR-->
67 67
68 <div class="module rounded sidebar"> 68 <div class="module rounded sidebar">
69 <h3>Poll of the Week</h3>
70
71 <!--POTW-->
72 </div>
73
74 <div class="module rounded sidebar">
75 <h3>Affiliates</h3> 69 <h3>Affiliates</h3>
76 70
77 <ul> 71 <ul>
diff --git a/theme/layouts/subtle/layout.tpl b/theme/layouts/subtle/layout.tpl index acfe682..ac57aa7 100755 --- a/theme/layouts/subtle/layout.tpl +++ b/theme/layouts/subtle/layout.tpl
@@ -117,12 +117,6 @@ AudioPlayer.setup("http://fourisland.com/theme/js/audio-player/player.swf", {
117 117
118 <div id="sidebar"> 118 <div id="sidebar">
119 <!--EXTRASIDEBAR--> 119 <!--EXTRASIDEBAR-->
120
121 <div class="module rounded sidebar">
122 <h3>Poll of the Week</h3>
123
124 <!--POTW-->
125 </div>
126 120
127 <div class="module rounded sidebar"> 121 <div class="module rounded sidebar">
128 <h3>Affiliates</h3> 122 <h3>Affiliates</h3>
diff --git a/theme/pollIndex.tpl b/theme/pollIndex.tpl index 35e7fe2..d3788db 100755 --- a/theme/pollIndex.tpl +++ b/theme/pollIndex.tpl
@@ -1,9 +1,5 @@
1<h2 class="light-at-night">Poll of the Week</h2> 1<h2 class="light-at-night">Poll of the Week</h2>
2 2
3<div class="module rounded sidebar center">
4 <!--POTW-->
5</div>
6
7<p class="light-at-night">Welcome to the Poll of the Week! Feel free to vote on these! You can review old ones and also comment on them if you're logged in using the links below!</p> 3<p class="light-at-night">Welcome to the Poll of the Week! Feel free to vote on these! You can review old ones and also comment on them if you're logged in using the links below!</p>
8 4
9<table class="webmail"> 5<table class="webmail">
@@ -12,13 +8,3 @@
12 <tr<!--POLL.EVEN-->><td><a href="/poll/<!--POLL.ID-->.php"><!--POLL.QUESTION--></a></td><td class="nobr"><!--POLL.WEEK--></td></tr> 8 <tr<!--POLL.EVEN-->><td><a href="/poll/<!--POLL.ID-->.php"><!--POLL.QUESTION--></a></td><td class="nobr"><!--POLL.WEEK--></td></tr>
13 <!--END POLL--> 9 <!--END POLL-->
14</table> 10</table>
15
16<p>
17 <!--BEGIN PREVIOUS-->
18 <a href="/poll/?start=<!--PREVIOUS.ID-->" style="float: left">Previous</a>
19 <!--END PREVIOUS-->
20
21 <!--BEGIN NEXT-->
22 <a href="/poll/?start=<!--NEXT.ID-->" style="float: right">Next</a>
23 <!--END NEXT-->
24</p>