-
Notifications
You must be signed in to change notification settings - Fork 29
/
signup.php
221 lines (204 loc) · 12.2 KB
/
signup.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
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
<?
/*
// +--------------------------------------------------------------------------+
// | 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();
if ($deny_signup && !$allow_invite_signup)
stderr($tracker_lang['error'], "Èçâèíèòå, íî ðåãèñòðàöèÿ îòêëþ÷åíà àäìèíèñòðàöèåé.");
if ($CURUSER)
stderr($tracker_lang['error'], sprintf($tracker_lang['signup_already_registered'], $SITENAME));
list($users) = mysql_fetch_array(sql_query("SELECT COUNT(id) FROM users"));
if ($users >= $maxusers)
stderr($tracker_lang['error'], sprintf($tracker_lang['signup_users_limit'], number_format($maxusers)));
if ($_POST["agree"] != "yes") {
stdhead("Ïðàâèëà òðåêåðà");
?>
<div style="width:80%" align="center">
<fieldset class="fieldset">
<legend>Ïðàâèëà òðåêåðà</legend>
<form method="post" action="<?=$PHP_SELF?>">
<table cellpadding="4" cellspacing="0" border="0" style="width:100%" class="tableinborder">
<tr>
<td class="tablea">Äëÿ ïðîäîëæåíèÿ ðåãèñòðàöèè, Âû äîëæíû ñîãëàñèòüñÿ ñî ñëåäóþùèìè ïðàâèëàìè:</td></tr>
<tr>
<td class="tablea" style="font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif">
<div class="page" style="border-right: thin inset; padding-right: 6px; border-top: thin inset; padding-left: 6px; padding-bottom: 6px; overflow: auto; border-left: thin inset; padding-top: 1px; border-bottom: thin inset; height: 170px">
<p><strong>Ïðàâèëà òðåêåðà</strong></p>
<p>Ðåãèñòðàöèÿ íà òðåêåðå àáñîëþòíî áåñïëàòíà! Íàñòîÿòåëüíî ðåêîìåíäóåì îçíàêîìèòüñÿ ñ ïðàâèëàìè íàøåãî ïðîåêòà.
Åñëè âû ñîãëàñíû ñî âñåìè óñëîâèÿìè, ïîñòàâüòå ãàëî÷êó ðÿäîì ñ 'ß ñîãëàñåí' è íàæìèòå 'Ðåãèñòðàöèÿ'.
Åñëè âû ïåðåäóìàëè ðåãèñòðèðîâàòüñÿ, íàæìèòå <a href="<?=$DEFAULTBASEURL;?>">çäåñü</a>, ÷òîáû âåðíóòüñÿ íà ãëàâíóþ ñòðàíèöó.</p>
<p>Õîòÿ ìîäåðàòîðû è àäìèíèñòðàòîðû, îáñëóæèâàþùèå <?=$SITENAME;?>, ñòàðàþòñÿ óäàëÿòü âñå îñêîðáèòåëüíûå è íåêîððåêòíûå
ñîîáùåíèÿ èç òðåêåðà, âñå ðàâíî âñå ñîîáùåíèÿ ïðîñìîòðåòü íåâîçìîæíî. Ñîîáùåíèÿ îòðàæàþò òî÷êó çðåíèÿ òîëüêî
àâòîðà, íî íå àäìèíèñòðàöèè òðåêåðà, ñîîòâåòñòâåííî òîëüêî àâòîð íåñåò îòâåòñòâåííîñòü çà ñîäåðæàíèå ñîîáùåíèÿ.</p>
<p>Ñîãëàøàÿñü ñ íàøèìè ïðàâèëàìè, âû îáÿçóåòåñü âûïîëíÿòü òðåáîâàíèÿ òðåêåðà â öåëîì, à òàêæå òðåáîâàíèÿ çàêîíîäàòåëüñòâà ÐÔ.</p>
<p>Àäìèíèñòðàöèÿ òðåêåðà îñòàâëÿåò çà ñîáîé ïðàâî óäàëÿòü, èçìåíÿòü, ïåðåíîñèòü èëè çàêðûâàòü ëþáóþ òåìó èëè ñîîáùåíèå ïî ñâîåìó óñìîòðåíèþ.</p>
</div>
</td></tr>
<tr><td class="tablea">
<div>
<label>
<input class="tablea" type="checkbox" name="agree" value="yes">
<input type="hidden" name="do" value="register">
<strong>ß ñîãëàñåí èñïîëíÿòü óñòàíîâëåííûå ïðàâèëà, ïîñåùàÿ <?=$SITENAME;?>.</strong>
</label>
</div>
</td></tr>
</table>
</fieldset><p>
<center>
<input class="tableinborder" type="submit" value="Ðåãèñòðàöèÿ">
</center>
</form>
<?
stdfoot();
die;
}
stdhead($tracker_lang['signup_signup']);
$countries = "<option value=\"0\">".$tracker_lang['signup_not_selected']."</option>\n";
$ct_r = sql_query("SELECT id, name FROM countries ORDER BY name") or die;
while ($ct_a = mysql_fetch_array($ct_r))
$countries .= "<option value=\"$ct_a[id]\">$ct_a[name]</option>\n";
?>
<span style="color: red; font-weight: bold;"><?=$tracker_lang['signup_use_cookies'];?></span>
<?
if ($deny_signup && $allow_invite_signup)
stdmsg("Âíèìàíèå", "Ðåãèñòðàöèÿ äîñòóïíà òîëüêî òåì ó êîãî åñòü êîä ïðèãëàøåíèÿ!");
?>
<p>
<form method="post" action="takesignup.php">
<table border="1" cellspacing=0 cellpadding="10">
<tr><td align="right" class="heading"><?=$tracker_lang['signup_username'];?></td><td align=left><input type="text" size="40" name="wantusername" /></td></tr>
<tr><td align="right" class="heading"><?=$tracker_lang['signup_password'];?></td><td align=left><input type="password" size="40" name="wantpassword" /></td></tr>
<tr><td align="right" class="heading"><?=$tracker_lang['signup_password_again'];?></td><td align=left><input type="password" size="40" name="passagain" /></td></tr>
<tr valign=top><td align="right" class="heading"><?=$tracker_lang['signup_email'];?></td><td align=left><input type="text" size="40" name="email" />
<table width=250 border=0 cellspacing=0 cellpadding=0><tr><td class=embedded><font class=small><?=$tracker_lang['signup_email_must_be_valid'];?></td></tr>
</font></td></tr></table>
</td></tr>
<tr><td align="right" class="heading"><?=$tracker_lang['signup_gender'];?></td><td align=left><input type=radio name=gender value=1><?=$tracker_lang['signup_male'];?><input type=radio name=gender value=2><?=$tracker_lang['signup_female'];?></td></tr>
<?
$year .= "<select name=year><option value=\"0000\">".$tracker_lang['my_year']."</option>\n";
$i = "1920";
while ($i <= (date('Y',time())-13)) {
$year .= "<option value=" .$i. ">".$i."</option>\n";
$i++;
}
$year .= "</select>\n";
$birthmonths = array(
"01" => $tracker_lang['my_months_january'],
"02" => $tracker_lang['my_months_february'],
"03" => $tracker_lang['my_months_march'],
"04" => $tracker_lang['my_months_april'],
"05" => $tracker_lang['my_months_may'],
"06" => $tracker_lang['my_months_june'],
"07" => $tracker_lang['my_months_jule'],
"08" => $tracker_lang['my_months_august'],
"09" => $tracker_lang['my_months_september'],
"10" => $tracker_lang['my_months_october'],
"11" => $tracker_lang['my_months_november'],
"12" => $tracker_lang['my_months_december'],
);
$month = "<select name=\"month\"><option value=\"00\">".$tracker_lang['my_month']."</option>\n";
foreach ($birthmonths as $month_no => $show_month) {
$month .= "<option value=$month_no>$show_month</option>\n";
}
$month .= "</select>\n";
$day .= "<select name=day><option value=\"00\">".$tracker_lang['my_day']."</option>\n";
$i = 1;
while ($i <= 31) {
if ($i < 10) {
$day .= "<option value=0".$i.">0".$i."</option>\n";
} else {
$day .= "<option value=".$i.">".$i."</option>\n";
}
$i++;
}
$day .="</select>\n";
tr($tracker_lang['my_birthdate'], $year.$month.$day ,1);
tr($tracker_lang['my_country'], "<select name=country>\n$countries\n</select>",1);
tr($tracker_lang['signup_contact'], "<table cellSpacing=\"3\" cellPadding=\"0\" width=\"100%\" border=\"0\">
<tr>
<td style=\"font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif\">
".$tracker_lang['my_contact_icq']."<br />
<img alt src=pic/contact/icq.gif width=\"17\" height=\"17\">
<input maxLength=\"30\" size=\"25\" name=\"icq\"></td>
<td style=\"font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif\">
".$tracker_lang['my_contact_aim']."<br />
<img alt src=pic/contact/aim.gif width=\"17\" height=\"17\">
<input maxLength=\"30\" size=\"25\" name=\"aim\"></td>
</tr>
<tr>
<td style=\"font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif\">
".$tracker_lang['my_contact_msn']."<br />
<img alt src=pic/contact/msn.gif width=\"17\" height=\"17\">
<input maxLength=\"50\" size=\"25\" name=\"msn\"></td>
<td style=\"font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif\">
".$tracker_lang['my_contact_yahoo']."<br />
<img alt src=pic/contact/yahoo.gif width=\"17\" height=\"17\">
<input maxLength=\"30\" size=\"25\" name=\"yahoo\"></td>
</tr>
<tr>
<td style=\"font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif\">
".$tracker_lang['my_contact_skype']."<br />
<img alt src=pic/contact/skype.gif width=\"17\" height=\"17\">
<input maxLength=\"32\" size=\"25\" name=\"skype\"></td>
<td style=\"font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif\">
".$tracker_lang['my_contact_mirc']."<br />
<img alt src=pic/contact/mirc.gif width=\"17\" height=\"17\">
<input maxLength=\"30\" size=\"25\" name=\"mirc\"></td>
</tr>
</table>",1);
tr($tracker_lang['my_website'], "<input type=\"text\" name=\"website\" size=\"40\" value=\"\" />", 1);
if ($use_captcha && $users) {
include_once("include/captcha.php");
$hash = create_captcha();
tr("Êîä ïîäòâåðæäåíèÿ", "<input type=\"text\" name=\"imagestring\" size=\"20\" value=\"\" />
<p>Ïîæàëóéñòà, ââåäèòå òåêñò èçîáðàæåííûé íà êàðòèíêå âíèçó.<br />Ýòîò ïðîöåññ ïðåäîòâðàùàåò àâòîìàòè÷åñêóþ ðåãèñòðàöèþ.</p>
<table>
<tr>
<td class=\"block\" rowspan=\"2\">
<img id=\"captcha\" src=\"captcha.php?imagehash=$hash\" alt=\"Captcha\" ondblclick=\"document.getElementById('captcha').src = 'captcha.php?imagehash=$hash&' + Math.random();\" />
</td>
<td class=\"block\"><img src=\"themes/$ss_uri/images/reload.gif\" style=\"cursor: pointer;\" onclick=\"document.getElementById('captcha').src = 'captcha.php?imagehash=$hash&' + Math.random();\" /></td>
</tr>
<tr>
<td class=\"block\"><a href=\"captcha_mp3.php?imagehash=$hash\"><img src=\"themes/$ss_uri/images/listen.gif\" style=\"cursor: pointer;\" border=\"0\" /></a></td>
</tr>
</table>
<font color=\"red\">Êîä ÷óâñòâèòåëåí ê ðåãèñòðó</font><br />Êëèêíèòå äâà ðàçà íà êàðòèíêå, ÷òî-áû îáíîâèòü êàðòèíêó.<input type=\"hidden\" name=\"imagehash\" value=\"$hash\" />", 1);
}
if ($allow_invite_signup) {
tr("Êîä ïðèãëàøåíèÿ", "<p>Åñëè ó âàñ åñòü êîä ïðèãëàøåíèÿ îò ïðèãëàñèâøåãî òî ââåäèòå åãî íèæå.</p><input type=\"text\" name=\"invite\" maxlength=\"32\" size=\"32\" />", 1);
}
?>
<tr><td align="right" class="heading"></td><td align="left"><input type="checkbox" name="rulesverify" value="yes"> <?=$tracker_lang['signup_i_have_read_rules'];?><br />
<input type="checkbox" name="faqverify" value="yes"> <?=$tracker_lang['signup_i_will_read_faq'];?><br />
<input type="checkbox" name="ageverify" value="yes"> <?=$tracker_lang['signup_i_am_13_years_old_or_more'];?></td></tr>
<tr><td colspan="2" align="center"><input type="submit" value="<?=$tracker_lang['signup_signup'];?>" style='height: 25px'></td></tr>
</table>
</form>
<?
stdfoot();
?>