"._RESTRICTEDAREA."
"
.""._MODULEUSERS.""
.""._GOBACK."";
CloseTable();
include("footer.php");
die();
}
if ($view == 2 AND is_admin($admin)) {
$modpath .= "modules/$name/$file.php";
if (file_exists($modpath)) {
include($modpath);
} else {
die ("Sorry, such file doesn't exist...");
}
} elseif ($view == 2 AND !is_admin($admin)) {
$pagetitle = "- "._ACCESSDENIED."";
include("header.php");
title("$sitename: "._ACCESSDENIED."");
OpenTable();
echo ""._RESTRICTEDAREA."
"
.""._MODULESADMINS.""
.""._GOBACK."";
CloseTable();
include("footer.php");
die();
}
// VIEW == USERGROUPS
if ($view > 2 AND is_user($user)) {// || is_admin($admin)
$userInfo = getusrinfo($user);
$newView = $view - 2;
list($gname) = sql_fetch_row(sql_query("select gname from ".$prefix."_users_groups where gid=$newView", $dbi), $dbi);
list($confUID) = sql_fetch_row(sql_query("select uid from ".$prefix."_users_groups_users where gid=$newView AND uid=$userInfo[uid]", $dbi), $dbi);
if ($confUID == $userInfo[uid] || is_admin($admin)) {
$modpath="modules/$name/$file.php";
if (file_exists($modpath)) {
include($modpath);
} else {
die ("Sorry, such file doesn't exist...");
}
} else {
$pagetitle = "- "._ACCESSDENIED."";
include("header.php");
title("$sitename: "._ACCESSDENIED."");
OpenTable();
echo ""._RESTRICTEDAREA."
"
."We are Sorry but this section of our site is for $gname Only
"
.""._GOBACK."";
CloseTable();
include("footer.php");
die();
}
} elseif ($view > 2 AND !is_user($user)) {
$pagetitle = "- "._ACCESSDENIED."";
include("header.php");
title("$sitename: "._ACCESSDENIED."");
OpenTable();
echo ""._RESTRICTEDAREA."
"
.""._MODULEUSERS.""
.""._GOBACK."";
CloseTable();
include("footer.php");
die();
}
}
} else {
include("header.php");
OpenTable();
echo ""._MODULENOTACTIVE."
"
.""._GOBACK."";
CloseTable();
include("footer.php");
}
} else {
die ("Sorry, you can't access this file directly...");
}
?>