forked from yunasc/tbdev
-
Notifications
You must be signed in to change notification settings - Fork 0
/
indexadd.php
107 lines (97 loc) · 5.74 KB
/
indexadd.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
106
107
<?
/*
// +--------------------------------------------------------------------------+
// | Project: TBDevYSE - TBDev Yuna Scatari Edition |
// +--------------------------------------------------------------------------+
// | This file is part of TBDevYSE. TBDevYSE is based on TBDev, |
// | originally by RedBeard of TorrentBits, extensively modified by |
// | Gartenzwerg. |
// | |
// | TBDevYSE is free software; you can redistribute it and/or modify |
// | it under the terms of the GNU General Public License as published by |
// | the Free Software Foundation; either version 2 of the License, or |
// | (at your option) any later version. |
// | |
// | TBDevYSE is distributed in the hope that it will be useful, |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
// | GNU General Public License for more details. |
// | |
// | You should have received a copy of the GNU General Public License |
// | along with TBDevYSE; if not, write to the Free Software Foundation, |
// | Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
// +--------------------------------------------------------------------------+
// | Do not remove above lines! |
// +--------------------------------------------------------------------------+
*/
require_once("include/bittorrent.php");
dbconn();
loggedinorreturn();
if (get_user_class() < UC_MODERATOR)
stderr($tracker_lang["error"], $tracker_lang["access_denied"]);
$types = array(
"notemplate" => array("type" => "notemplate", "name" => "Áåç øàáëîíà"),
"video" => array("type" => "video", "name" => "Âèäåî"),
"games" => array("type" => "games", "name" => "Èãðû"),
"music" => array("type" => "music", "name" => "Ìóçûêà"),
"soft" => array("type" => "soft", "name" => "Ïðîãðàììû"),
);
$templates = array(
"notemplate" => array("toptemplate" => "", "centertemplate" => "", "bottomtemplate" => ""),
"video" => array("toptemplate" => "[b]Æàíð:[/b] \n[b]Ðåæèññåð:[/b] \n[b] ðîëÿõ:[/b] ", "centertemplate" => "[b]Î ôèëüìå:[/b] ", "bottomtemplate" => "[b]Êà÷åñòâî:[/b] \n[b]Âèäåî:[/b] \n[b]Àóäèî:[/b] \n[b]Ïðîäîëæèòåëüíîñòü:[/b] \n[b]ßçûê:[/b] \n[b]Ïåðåâîä:[/b] "),
"music" => array("toptemplate" => "[b]Èñïîëíèòåëü:[/b] \n[b]Àëüáîì:[/b] \n[b]Ãîä âûïóñêà:[/b] \n[b]Ñòèëü:[/b] ", "centertemplate" => "[b]Òðåêëèñò:[/b] ", "bottomtemplate" => "[b]Çâóê:[/b] \n[b]Ïðîäîëæèòåëüíîñòü:[/b] "),
"games" => array("toptemplate" => "[b]Íàçâàíèå:[/b] \n[b]Ïðîèçâîäèòåëü:[/b] \n[b]Æàíð:[/b] \n[b]Ãîä âûïóñêà:[/b] ", "centertemplate" => "[b]Îïèñàíèå:[/b] ", "bottomtemplate" => "[b]Ñèñòåìíûå òðåáîâàíèÿ:[/b] \n[b]Ñêðèíû:[/b] "),
"soft" => array("toptemplate" => "[b]Íàçâàíèå:[/b] \n[b]Ïðîèçâîäèòåëü:[/b] \n[b]Ãîä âûïóñêà:[/b] ", "centertemplate" => "[b]Îïèñàíèå:[/b] ", "bottomtemplate" => "[b]Ñèñòåìíûå òðåáîâàíèÿ:[/b] "),
);
if (empty($_GET["type"])) {
stdhead("Âûáåðèòå òèï ðåëèçà");
?>
<form action="indexadd.php" method="get">
<table border="1" cellspacing="0" cellpadding="3" width="20%">
<tr><td class="heading" align="right">Òèï</td><td>
<select name="type">
<?
foreach ($types as $type)
print("<option value=\"" . $type["type"] . "\">" . $type["name"] . "</option>");
?>
</select>
</td></tr>
<tr><td align="center" colspan="2"><input type="submit" class=btn value="Äàëüøå"></td></tr>
</table>
</form>
<?
stdfoot();
die;
} else
$type = $_GET["type"];
stdhead("Äîáàâèòü ðåëèç - ".$types[$type]["name"]);
$cats = genrelist();
$categories = "<select name=\"cat\"><option selected>Âûáåðèòå êàòåãîðèþ</option>";
foreach ($cats as $cat) {
$cat_id = $cat["id"];
$cat_name = $cat["name"];
$categories .= "<option value=\"$cat_id\">$cat_name</option>";
}
$categories .= "</select>";
?>
<form name="index" action="takeindex.php" method="post">
<table border="0" cellspacing="0" cellpadding="5">
<tr><td class="colhead" colspan="2">Âûáðàííûé øàáëîí: <?=$types[$type]["name"];?></td></tr>
<?
tr("Íàçâàíèå ðåëèçà", "<input type=\"text\" name=\"name\" size=\"80\" /><br />Ïðèìåð: Ñìåðòü Ïðåçèäåíòà (2006) DVDRip\n", 1);
tr("Ïîñòåð", "<input type=\"text\" name=\"poster\" size=\"80\" /><br />Çàëèòü êàðòèíêó íà <a href=\"http://www.imageshack.us\">ImageShack</a>", 1);
?>
<tr><td width="" class="heading" valign="top" align="right">Âåðõíèé øàáëîí</td><td valign="top" align="left"><?=textbbcode("index", "top", $templates[$type]["toptemplate"]);?></td></tr>
<tr><td width="" class="heading" valign="top" align="right">Ñðåäíèé øàáëîí</td><td valign="top" align="left"><?=textbbcode("index", "center", $templates[$type]["centertemplate"]);?></td></tr>
<tr><td width="" class="heading" valign="top" align="right">Íèæíèé øàáëîí</td><td valign="top" align="left"><?=textbbcode("index", "bottom", $templates[$type]["bottomtemplate"]);?></td></tr>
<?
tr("Íîìåð òîððåíòà", "<input type=\"text\" name=\"torrentid\" size=\"60\" /><br />Ïðèìåð: $DEFAULTBASEURL/details.php?id=<b>6764</b><br />Âûäåëåííîå æèðíûì - è åñòü íîìåð òîððåíòà\n", 1);
tr("URL IMDB", "<input type=\"text\" name=\"imdb\" size=\"60\" /><br />Ïðèìåð: http://www.imdb.com/title/tt0408306/\n", 1);
tr("Êàòåãîðèÿ", $categories, 1);
?>
<tr><td align="center" colspan="2"><input type="submit" value="Äîáàâèòü" /></td></tr>
</table>
</form>
<?
stdfoot();
?>