Gazelle/sections/user/invitetree.php

36 lines
986 B
PHP
Raw Normal View History

2012-03-28 08:00:20 +00:00
<?
2013-04-17 08:00:58 +00:00
if (isset($_GET['userid']) && check_perms('users_view_invites')) {
if (!is_number($_GET['userid'])) {
error(403);
}
2013-02-22 08:00:24 +00:00
2013-04-17 08:00:58 +00:00
$UserID = $_GET['userid'];
2012-03-28 08:00:20 +00:00
$Sneaky = true;
} else {
2013-04-17 08:00:58 +00:00
if (!$UserCount = $Cache->get_value('stats_user_count')) {
2012-03-28 08:00:20 +00:00
$DB->query("SELECT COUNT(ID) FROM users_main WHERE Enabled='1'");
list($UserCount) = $DB->next_record();
$Cache->cache_value('stats_user_count', $UserCount, 0);
}
2013-02-22 08:00:24 +00:00
2012-03-28 08:00:20 +00:00
$UserID = $LoggedUser['ID'];
$Sneaky = false;
}
2012-10-11 08:00:15 +00:00
list($UserID, $Username, $PermissionID) = array_values(Users::user_info($UserID));
2012-03-28 08:00:20 +00:00
2013-05-27 08:00:58 +00:00
include(SERVER_ROOT.'/classes/invite_tree.class.php');
2012-03-28 08:00:20 +00:00
$Tree = new INVITE_TREE($UserID);
2012-10-11 08:00:15 +00:00
View::show_header($Username.' &gt; Invites &gt; Tree');
2012-03-28 08:00:20 +00:00
?>
<div class="thin">
2012-08-19 08:00:19 +00:00
<div class="header">
2012-10-11 08:00:15 +00:00
<h2><?=Users::format_username($UserID, false, false, false)?> &gt; <a href="user.php?action=invite&amp;userid=<?=$UserID?>">Invites</a> &gt; Tree</h2>
2012-08-19 08:00:19 +00:00
</div>
2012-03-28 08:00:20 +00:00
<div class="box pad">
<? $Tree->make_tree(); ?>
</div>
</div>
2013-04-17 08:00:58 +00:00
<? View::show_footer(); ?>