diff --git a/preferences/inc/hook_preferences.inc.php b/preferences/inc/hook_preferences.inc.php index 6d30398d19..c368111f70 100644 --- a/preferences/inc/hook_preferences.inc.php +++ b/preferences/inc/hook_preferences.inc.php @@ -16,7 +16,7 @@ { $file['Change your Password'] = $GLOBALS['phpgw']->link('/preferences/changepassword.php'); } - $file['change your settings'] = $GLOBALS['phpgw']->link('/preferences/preferences.php','appname=preferences'); + $file['change your settings'] = $GLOBALS['phpgw']->link('/preferences/preferences.php','appname=preferences&type=user'); display_section('Preferences','Preferences',$file); diff --git a/preferences/preferences.php b/preferences/preferences.php index b8c7446c6a..eacc3fdb76 100755 --- a/preferences/preferences.php +++ b/preferences/preferences.php @@ -23,6 +23,7 @@ $user = get_var('user',Array('POST')); $global = get_var('global',Array('POST')); $default = get_var('default',Array('POST')); + $GLOBALS['appname'] = get_var('appname',Array('GET')); if(get_var('cancel',Array('POST'))) @@ -208,7 +209,7 @@ $GLOBALS['phpgw']->session->appsession('session_data','preferences',$session_data); } - $type = get_var('type',Array('GET')); + $type = get_var('type',Array('GET','POST')); if (!isset($type)) { $GLOBALS['type'] = $session_data['type']; @@ -258,7 +259,7 @@ if (get_var('submit',Array('POST'))) { /* Don't use a switch here, we need to check some permissions durring the ifs */ - if ($GLOBALS['type'] == 'user') + if ($GLOBALS['type'] == 'user' || !($GLOBALS['type'])) { process_array($p, $user); }