From a65f93478f2c0756c2096d429433040060be8635 Mon Sep 17 00:00:00 2001
From: redray <redray@ispconfig3>
Date: Mon, 15 Dec 2008 07:21:14 -0500
Subject: [PATCH] fixed a bug

---
 interface/web/sites/tools.inc.php |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/interface/web/sites/tools.inc.php b/interface/web/sites/tools.inc.php
index 2047400..a7c6cf6 100644
--- a/interface/web/sites/tools.inc.php
+++ b/interface/web/sites/tools.inc.php
@@ -1,6 +1,6 @@
 <?php
 /*
-Copyright (c) 2007, Till Brehm, projektfarm Gmbh
+Copyright (c) 2008, Till Brehm, projektfarm Gmbh
 All rights reserved.
 
 Redistribution and use in source and binary forms, with or without modification,
@@ -38,7 +38,7 @@
                         $res=str_replace('['.$keyword.']', getClientName($dataRecord), $name);        
                         break;
                     case 'CLIENTID':
-                        $res=str_replace('['.$keyword.']', '000', $name);        
+                        $res=str_replace('['.$keyword.']', getClientID($dataRecord), $name);        
                         break;
                 }
             }
@@ -79,8 +79,8 @@
     	$client_group_id = $dataRecord['client_group_id'];
     }
     /* get the name of the client */
-    $tmp = $app->db->queryOneRecord("SELECT id FROM sys_group WHERE groupid = " . $client_group_id);
-    $clientID = $tmp['id'];
+    $tmp = $app->db->queryOneRecord("SELECT client_id FROM sys_group WHERE groupid = " . $client_group_id);
+    $clientID = $tmp['client_id'];
     if ($clientID == '') $clientID = '0';
     return $clientID;
 }

--
Gitblit v1.9.1