From 9aaa057aed498d0b9fce5751403d04832a6ee738 Mon Sep 17 00:00:00 2001 From: hickert Date: Fri, 10 Feb 2006 08:05:35 +0000 Subject: [PATCH] Fixed attribute saving git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2654 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../environment/class_environment.inc | 29 ++++++++++--------- 1 file changed, 16 insertions(+), 13 deletions(-) diff --git a/plugins/personal/environment/class_environment.inc b/plugins/personal/environment/class_environment.inc index 2a3613535..059b35c20 100644 --- a/plugins/personal/environment/class_environment.inc +++ b/plugins/personal/environment/class_environment.inc @@ -757,12 +757,27 @@ class environment extends plugin /* Save to LDAP */ function save() { + + /* only save changed variables ....*/ + if ($this->gotoKioskProfile =="none") $this->gotoKioskProfile =""; + if((!empty($this->gotoKioskProfile))&&($this->gotoKioskProfile != "none")){ + if(preg_match("/https/i",$_SERVER['HTTP_REFERER'])){ + $method="https://"; + }else{ + $method="http://"; + } + + $str = $method.str_replace("//","/",$_SERVER['SERVER_NAME']."/kiosk/"); + $this->gotoKioskProfile= $str.$this->gotoKioskProfile; + }else{ + $this->gotoKioskProfile= array(); + } + plugin::save(); $ldap= $this->config->get_ldap_link(); $realyUsedAttrs= array(); - $path = search_config($this->config->data,"environment", "KIOSKPATH"); /* Creating Kiosk Profiles */ foreach($this->newKioskProfiles as $file){ @@ -958,18 +973,6 @@ class environment extends plugin $this->attrs['gotoShare'][] =$share['server']."|".$share['name']."|".$share['mountPoint']."|".$share['OtherStuff']."|".$share['Username']; } - if((!empty($this->gotoKioskProfile))&&($this->gotoKioskProfile != "none")){ - if(preg_match("/https/i",$_SERVER['HTTP_REFERER'])){ - $method="https://"; - }else{ - $method="http://"; - } - - $str = $method.str_replace("//","/",$_SERVER['SERVER_NAME']."/kiosk/"); - $this->attrs['gotoKioskProfile']= $str.$this->gotoKioskProfile; - }else{ - $this->attrs['gotoKioskProfile']= array(); - } $saveThis = array("gotoProfileQuota","gotoXResolution","gotoProfileServer"); -- 2.30.2