-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathok.php
83 lines (74 loc) · 2.53 KB
/
ok.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
<?php
/**
* http://btdev.net:1337/svn/test/Installer09_Beta
* Licence Info: GPL
* Copyright (C) 2010 BTDev Installer v.1
* A bittorrent tracker source based on TBDev.net/tbsource/bytemonsoon.
* Project Leaders: Mindless,putyn.
**/
require_once(dirname(__FILE__).DIRECTORY_SEPARATOR.'include'.DIRECTORY_SEPARATOR.'bittorrent.php');
require_once(INCL_DIR.'user_functions.php');
global $CURUSER;
if(!$CURUSER){
get_template();
}
dbconn();
$lang = array_merge( load_language('global'), load_language('ok') );
$type = isset($_GET['type']) ? $_GET['type'] : '';
$HTMLOUT = '';
if ( $type == "signup" && isset($_GET['email']) )
{
stderr( "{$lang['ok_success']}", sprintf($lang['ok_email'], htmlentities($_GET['email'], ENT_QUOTES)) );
}
elseif ( $type == "invite" && isset($_GET['email']) )
{
stderr( "{$lang['ok_invsuccess']}", sprintf($lang['ok_email2'], htmlentities($_GET['email'], ENT_QUOTES)) );
}
elseif ($type == "sysop")
{
$HTMLOUT = stdhead("{$lang['ok_sysop_account']}");
$HTMLOUT .= "{$lang['ok_sysop_activated']}";
if (isset($CURUSER))
{
$HTMLOUT .= "{$lang['ok_account_activated']}";
}
else
{
$HTMLOUT .= "{$lang['ok_account_login']}";
}
$HTMLOUT .= stdfoot();
print $HTMLOUT;
}
elseif ($type == "confirmed")
{
$HTMLOUT .= stdhead("{$lang['ok_confirmed']}");
$HTMLOUT .= "<h1>{$lang['ok_confirmed']}</h1>\n";
$HTMLOUT .= "{$lang['ok_user_confirmed']}";
$HTMLOUT .= stdfoot();
print $HTMLOUT;
}
elseif ($type == "confirm")
{
if (isset($CURUSER))
{
$HTMLOUT .= stdhead("{$lang['ok_signup_confirm']}");
$HTMLOUT .= "<h1>{$lang['ok_success_confirmed']}</h1>\n";
$HTMLOUT .= "<p>".sprintf($lang['ok_account_active_login'], "<a href='{$TBDEV['baseurl']}/index.php'><b>{$lang['ok_account_active_login_link']}</b></a>")."</p>\n";
$HTMLOUT .= sprintf($lang['ok_read_rules'], $TBDEV['site_name']);
$HTMLOUT .= stdfoot();
print $HTMLOUT;
}
else
{
$HTMLOUT .= stdhead("{$lang['ok_signup_confirm']}");
$HTMLOUT .= "<h1>{$lang['ok_success_confirmed']}</h1>\n";
$HTMLOUT .= "{$lang['ok_account_cookies']}";
$HTMLOUT .= stdfoot();
print $HTMLOUT;
}
}
else
{
stderr("{$lang['ok_user_error']}", "{$lang['ok_no_action']}");
}
?>