zusätzliche include auch ins repo
bernd

bernd commited on 2007-11-27 06:16:45
Zeige 1 geänderte Dateien mit 18 Einfügungen und 0 Löschungen.


git-svn-id: https://svn.schokokeks.org/repos/tools/webinterface/trunk@813 87cf0b9e-d624-0410-a070-f6ee81989793
... ...
@@ -0,0 +1,18 @@
1
+<?php
2
+
3
+function user_has_vmail_domain() 
4
+{
5
+	$role = $_SESSION['role'];
6
+	if (! ($role & ROLE_SYSTEMUSER)) {
7
+		return false;
8
+	}
9
+	$uid = (int) $_SESSION['userinfo']['uid'];
10
+	$result = db_query("SELECT COUNT(*) FROM mail.v_vmail_domains WHERE useraccount='{$uid}'");
11
+	$row = mysql_fetch_array($result);
12
+	$count = $row[0];
13
+	DEBUG("User has {$count} vmail-domains");
14
+	return ( (int) $count > 0 );
15
+}
16
+
17
+
18
+?>
0 19