-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtab_forceupdates.php
57 lines (46 loc) · 1.84 KB
/
tab_forceupdates.php
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
<div class="section">
<h1>Force updates requested or approved by admins</h1>
<table width="100%" border="0" cellspacing="0" cellpadding="2" align="center">
<tr>
<td class="head">Series ID</td>
<td class="head">Series Name</td>
</tr>
<?php ## Display series
$count = 0;
$query = "SELECT * FROM games WHERE forceupdate=2 ORDER BY SeriesName";
$result = mysql_query($query) or die('Query failed: ' . mysql_error());
while ($db = mysql_fetch_object($result)) {
if ($class == 'odd') { $class = 'even'; } else { $class = 'odd'; }
print "<tr><td class=\"$class\"><a href=\"/?tab=series&id=$db->id\">$db->id</a></td><td class=\"$class\"><a href=\"/?tab=series&id=$db->id\">$db->SeriesName</a></td></tr>\n";
$count++;
}
## No matches found?
if ($count == 0) {
print "<tr><td class=odd colspan=2>No series found</td></tr>\n";
}
?>
</table>
</div>
<div class="section">
<h1>Force updates requested by users and not yet approved by admins</h1>
<table width="100%" border="0" cellspacing="0" cellpadding="2" align="center">
<tr>
<td class="head">Series ID</td>
<td class="head">Series Name</td>
</tr>
<?php ## Display series
$count = 0;
$query = "SELECT * FROM games WHERE forceupdate=1 ORDER BY SeriesName";
$result = mysql_query($query) or die('Query failed: ' . mysql_error());
while ($db = mysql_fetch_object($result)) {
if ($class == 'odd') { $class = 'even'; } else { $class = 'odd'; }
print "<tr><td class=\"$class\"><a href=\"/?tab=series&id=$db->id\">$db->id</a></td><td class=\"$class\"><a href=\"/?tab=series&id=$db->id\">$db->SeriesName</a></td></tr>\n";
$count++;
}
## No matches found?
if ($count == 0) {
print "<tr><td class=odd colspan=2>No series found</td></tr>\n";
}
?>
</table>
</div>