-
Notifications
You must be signed in to change notification settings - Fork 0
/
viewshow.php
executable file
·105 lines (85 loc) · 2.43 KB
/
viewshow.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
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
<?php
include('includes/includes.php');;
$showID=$_GET['showid'];
$showName=bd_getShowTitle($showID);
$season = $_GET['season'];
$totalseasons = bd_countSeasonsShow($showID);
$totaleps = bd_countEpisodesShow($showID);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>Subtítols – <?php echo "$showName - wikisubtitles"; ?></title>
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />
<script type="text/javascript" src="/js/mootools.v1.11.js"></script>
<script type="text/javascript">
<?php include('js/quicksearch.php'); ?>
</script>
<style type="text/css" media="screen">
@import url(/css/main.css);
</style>
<script type="text/javascript">
function loadShow(show, season)
{
$("episodes").innerHTML = '<img src="/images/loader.gif" />';
new Ajax('/ajax_loadShow.php?show='+show+'&season='+season, {
method: 'get',
update: $("episodes")
}).request();
}
</script>
</head>
<?php
$query = "select min(season) from files where showID=$showID";
$result = mysql_query($query);
$min = mysql_result($result, 0);
if (!isset($season) )
$fseason = $min;
else
$fseason = $season;
echo "<body onload=\"loadShow($showID,$fseason);\">";
?>
<?php include("header.php"); ?>
<?php include("includes/general/nav_home.php"); ?>
<div id="sitebody">
<div id="slogan">
<h2><a href="/shows.php"><?php echo $wikilang_explore_by_show; ?></a> / <?php echo $showName; ?> (<?php echo " $totalseasons $wikilang_seasons "; ?> · <?php echo " $totaleps $wikilang_episodes" ?>)</h2>
</div>
<span id="episodes"></span>
<table width="40%" border="1">
<tr>
<td> </td>
<td colspan="2" class="titulo">
</td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</td>
</tr>
<tr>
<td> </td>
<td> </td>
<td class="titulo"> </td>
<td><span class="titulo">
<?php
echo $wikilang_season.' ';
$query = "select distinct(season) from files where is_episode=1 and showID=$showID order by season";
$sresult = mysql_query($query);
for ($c=0; $c<$totalseasons; $c++)
{
$myseason = mysql_result($sresult, $c, 0);
echo "<a href=\"javascript:loadShow($showID,$myseason)\">$myseason</a> ";
}
?>
</span></td>
</tr>
</table>
<?php
include('footer.php');
bbdd_close();
?>
</body>
</html>