From 1e45da277b6e28ff65967d38c12b298872efb059 Mon Sep 17 00:00:00 2001 From: tbrehm <t.brehm@ispconfig.org> Date: Fri, 01 Aug 2008 17:37:59 -0400 Subject: [PATCH] Added translation functions for the tabs of forms. --- interface/web/sites/web_domain_edit.php | 12 ++++-------- 1 files changed, 4 insertions(+), 8 deletions(-) diff --git a/interface/web/sites/web_domain_edit.php b/interface/web/sites/web_domain_edit.php index 5c571c2..336a538 100644 --- a/interface/web/sites/web_domain_edit.php +++ b/interface/web/sites/web_domain_edit.php @@ -41,11 +41,8 @@ require_once('../../lib/config.inc.php'); require_once('../../lib/app.inc.php'); -// Checking module permissions -if(!stristr($_SESSION["s"]["user"]["modules"],'sites')) { - header("Location: ../index.php"); - exit; -} +//* Check permissions for module +$app->auth->check_module_permissions('sites'); // Loading classes $app->uses('tpl,tform,tform_actions'); @@ -97,7 +94,7 @@ // Get the limits of the client $client_group_id = $_SESSION["s"]["user"]["default_group"]; - $client = $app->db->queryOneRecord("SELECT limit_web_domain, default_webserver FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id"); + $client = $app->db->queryOneRecord("SELECT client_id, limit_web_domain, default_webserver FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id"); // Set the webserver to the default server of the client $tmp = $app->db->queryOneRecord("SELECT server_name FROM server WHERE server_id = $client[default_webserver]"); @@ -105,7 +102,7 @@ unset($tmp); // Fill the client select field - $sql = "SELECT groupid, name FROM sys_group WHERE client_id > 0"; + $sql = "SELECT groupid, name FROM sys_group, client WHERE sys_group.client_id = client.parent_client_id AND client.parent_client_id = ".$client['client_id']; $clients = $app->db->queryAllRecords($sql); $client_select = ''; if(is_array($clients)) { @@ -156,7 +153,6 @@ } } $app->tpl->setVar("client_group_id",$client_select); - } -- Gitblit v1.9.1