summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ab5fdf6)
raw | patch | inline | side by side (parent: ab5fdf6)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 31 Aug 2006 11:09:46 +0000 (11:09 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 31 Aug 2006 11:09:46 +0000 (11:09 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@4556 594d385d-05f5-0310-b6e9-bd551577e9d8
plugins/personal/environment/class_kioskManagementDialog.inc | patch | blob | history |
diff --git a/plugins/personal/environment/class_kioskManagementDialog.inc b/plugins/personal/environment/class_kioskManagementDialog.inc
index 33d577c289a840d0b2b8d2e5fe0bb2bd84d10927..217c7120c06661184df53e1548a992cd0d211037 100644 (file)
$only_once = false;
$id = preg_replace("/^delkiosk_/","",$name);
$id = preg_replace("/_.*$/","",$id);
-
- $filename = $this->baseDir."/".preg_replace("/^.*\//i","",base64_decode($id));
-
- $res = unlink($filename);
- if(!$res){
- if(!is_writeable($filename)){
- print_red(sprintf(_("Can't delete '%s'. Error was: permission denied."), $filename));
- }
- if(!file_exists($filename)){
- print_red(sprintf(_("Can't delete '%s'. Errow was: file doesn't exist."), $filename));
+
+ $name = preg_replace("/^.*\//i","",base64_decode($id));
+
+ $filename = $this->baseDir."/".$name;
+
+ if(isset($this->filesToAttach[$name])){
+ unset($this->filesToAttach[$name]);
+ }else{
+
+ $res = @unlink($filename);
+ if(!$res){
+ if(!is_writeable($filename)){
+ print_red(sprintf(_("Can't delete '%s'. Error was: permission denied."), $filename));
+ }
+ if(!file_exists($filename)){
+ print_red(sprintf(_("Can't delete '%s'. Errow was: file doesn't exist."), $filename));
+ }
}
}
}