From 8d52ea0dc753ec2e5afb9a2001dc96141a2ed17f Mon Sep 17 00:00:00 2001 From: skeeter Date: Thu, 28 Sep 2000 00:19:04 +0000 Subject: [PATCH] fixes with new db structures --- addressbook/edit.php | 13 +++++++------ addressbook/inc/functions.inc.php | 2 +- addressbook/index.php | 4 ++-- addressbook/view.php | 2 +- 4 files changed, 11 insertions(+), 10 deletions(-) diff --git a/addressbook/edit.php b/addressbook/edit.php index 95a502e6de..23e79b3f0b 100755 --- a/addressbook/edit.php +++ b/addressbook/edit.php @@ -27,7 +27,7 @@ if (! $submit) { $phpgw->db->query("SELECT * FROM addressbook WHERE ab_owner='" - . $phpgw_info["user"]["userid"] . "' AND ab_id='$ab_id'"); + . $phpgw_info["user"]["userid"] . "' AND ab_id=$ab_id"); $phpgw->db->next_record(); $fields = array('ab_id' => $phpgw->db->f("ab_id"), @@ -74,17 +74,17 @@ . "', ab_notes='" . addslashes($notes) . "', ab_company='" . addslashes($company) . "', ab_access='" . addslashes($access) - . "' WHERE ab_owner='" . $phpgw_info["user"]["userid"] . "' AND ab_id='$ab_id'"; + . "' WHERE ab_owner='" . $phpgw_info["user"]["userid"] . "' AND ab_id=$ab_id"; $phpgw->db->query($sql); - Header("Location: " . $phpgw->link("view.php","&con=$con&order=$order&sort=$sort&filter=" + Header("Location: " . $phpgw->link("view.php","&ab_id=$ab_id&order=$order&sort=$sort&filter=" . "$filter&start=$start")); exit; } ?> - + @@ -97,10 +97,10 @@ "> - " . lang("Cancel"); ?> + " . lang("Cancel"); ?> - " . lang("Delete"); ?> + " . lang("Delete"); ?> @@ -112,3 +112,4 @@ diff --git a/addressbook/inc/functions.inc.php b/addressbook/inc/functions.inc.php index be62daf37a..ce064c5dbd 100755 --- a/addressbook/inc/functions.inc.php +++ b/addressbook/inc/functions.inc.php @@ -282,5 +282,5 @@ diff --git a/addressbook/index.php b/addressbook/index.php index f5c31cba27..3fff25a5c5 100755 --- a/addressbook/index.php +++ b/addressbook/index.php @@ -71,11 +71,11 @@ nextmatchs->show("index.php",$start,$phpgw->db->f(0),"&order=$order&filter=$filter&sort=" - . "$sort&query=$query", "75%", $phpgw_info["theme"][th_bg]); + . "$sort&query=$query", "75%", $phpgw_info["theme"]["th_bg"]); ?> - "> + "> '; diff --git a/addressbook/view.php b/addressbook/view.php index e1d7f44c12..ceabc1bcd3 100755 --- a/addressbook/view.php +++ b/addressbook/view.php @@ -26,7 +26,7 @@ if ($filter != "private") $filtermethod = " or ab_access='public' " . $phpgw->accounts->sql_search("ab_access"); - $phpgw->db->query("SELECT * FROM addressbook WHERE ab_id='$ab_id' AND (ab_owner='" + $phpgw->db->query("SELECT * FROM addressbook WHERE ab_id=$ab_id AND (ab_owner='" . $phpgw_info["user"]["userid"] . "' $filtermethod)"); $phpgw->db->next_record();