From 587b3e218f6e8c1fbc3a34c5ee5a0f3039d06a52 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Sun, 6 Apr 2003 12:11:03 +0000 Subject: [PATCH] fix for not editable/deletable custom-fields with with certain special chars in there name, field-name was not url-encoded --- addressbook/inc/class.uifields.inc.php | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/addressbook/inc/class.uifields.inc.php b/addressbook/inc/class.uifields.inc.php index 82180e9662..4276fc107b 100644 --- a/addressbook/inc/class.uifields.inc.php +++ b/addressbook/inc/class.uifields.inc.php @@ -100,11 +100,21 @@ $title = $fields[$i]['title']; $GLOBALS['phpgw']->template->set_var('cfield',$title); - - $GLOBALS['phpgw']->template->set_var('edit',$GLOBALS['phpgw']->link('/index.php',"menuaction=addressbook.uifields.edit&field=$field&start=$start&query=$query&sort=$sort&order=$order&filter=$filter")); + + $params = array( + 'menuaction' => 'addressbook.uifields.edit', + 'field' => urlencode($field), + 'start' => $start, + 'query' => $query, + 'sort' => $sort, + 'order' => $order, + 'filter' => $filter + ); + $GLOBALS['phpgw']->template->set_var('edit',$GLOBALS['phpgw']->link('/index.php',$params)); $GLOBALS['phpgw']->template->set_var('lang_edit_entry',lang('Edit')); - $GLOBALS['phpgw']->template->set_var('delete',$GLOBALS['phpgw']->link('/index.php',"menuaction=addressbook.uifields.delete&field=$field&start=$start&query=$query&sort=$sort&order=$order&filter=$filter")); + $params['menuaction'] = 'addressbook.uifields.delete'; + $GLOBALS['phpgw']->template->set_var('delete',$GLOBALS['phpgw']->link('/index.php',$params)); $GLOBALS['phpgw']->template->set_var('lang_delete_entry',lang('Delete')); $GLOBALS['phpgw']->template->parse('list','field_list',True); }