Exemple #1
0
function errorInterface($ras_ip, $err)
{
    $smarty = new IBSSmarty();
    $smarty->assign("ras_ip", $ras_ip);
    $smarty->set_page_error($err->getErrorMsgs());
    $smarty->display("admin/ras/del_port.tpl");
}
function returnText($resp)
{
    $smarty = new IBSSmarty();
    if ($resp->isSuccessful()) {
        $smarty->assign("alerts", $resp->getResult());
    } else {
        $resp->setErrorInSmarty($smarty);
        $smarty->assign("alerts", array());
    }
    $smarty->display("admin/user/check_user_for_add.tpl");
}
Exemple #3
0
function showAccessDenied($auth_type)
{
    switch ($auth_type) {
        case ADMIN_AUTH_TYPE:
            $url = "/IBSng/admin";
            $role = "admin";
            break;
        default:
            $url = "/IBSng/admin";
            $role = "";
            break;
    }
    $smarty = new IBSSmarty();
    $smarty->assign_array(array("url" => $url, "role" => $role));
    $smarty->display("access_denied.tpl");
    exit;
}
Exemple #4
0
function getHelpErrorContents($msg)
{
    $smarty = new IBSSmarty();
    $smarty->assign("msg", $msg);
    return $smarty->fetch("help/error.tpl");
}
function intShowCategories()
{
    $smarty = new IBSSmarty();
    $smarty->assign("admin_username", $_REQUEST["admin_username"]);
    $smarty->display("admin/admins/perm_category_select.tpl");
}
<?php

require_once "../../inc/init.php";
require_once "search_user_funcs.php";
require_once "change_credit_funcs.php";
require_once "del_user_funcs.php";
require_once "../plugins/edit_funcs.php";
require_once IBSINC . "report.php";
needAuthType(ADMIN_AUTH_TYPE);
$smarty = new IBSSmarty();
$user_ids = getSelectedUserIDsFromRequest();
if (sizeof($user_ids) == 0) {
    $smarty->set_page_error("No users selected!");
    intShowUserSearch($smarty);
} else {
    if (isInRequest("edit")) {
        searchUserEdit($smarty, $user_ids);
    } else {
        if (isInRequest("change_credit")) {
            changeUserCredit($smarty, $user_ids);
        } else {
            if (isInRequest("connection_log")) {
                showConnectionLogs($smarty, $user_ids);
            } else {
                if (isInRequest("credit_change")) {
                    showCreditChanges($smarty, $user_ids);
                } else {
                    if (isInRequest("delete_users")) {
                        showDeleteUserFace($smarty, $user_ids);
                    }
                }