inc/record.inc.php
changeset 169 41353c2e0c9f
parent 161 0832d846bf8e
child 170 391e744a1def
--- a/inc/record.inc.php	Fri May 16 11:30:20 2008 +0000
+++ b/inc/record.inc.php	Sun May 18 07:56:11 2008 +0000
@@ -936,7 +936,7 @@
 	// Search for matching domains
 	if ($perm == "own") {
 		$sql_add_from = ", zones ";
-		$sql_add_where = " AND zones.domain_id = domains.id AND zones.owner = " . $db->quote($userid);
+		$sql_add_where = " AND zones.domain_id = domains.id AND zones.owner = " . $db->quote($_SESSION['userid']);
 	}
 	
 	$query = "SELECT 
@@ -963,7 +963,7 @@
 
 	if ($perm == "own") {
 		$sql_add_from = ", zones ";
-		$sql_add_where = " AND zones.domain_id = record.id AND zones.owner = " . $db->quote($userid);
+		$sql_add_where = " AND zones.domain_id = record.id AND zones.owner = " . $db->quote($_SESSION['userid']);
 	}
 
 	$query = "SELECT