Code

Updated handling of uploaded files, thanks to bcooksley
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 17 Nov 2010 09:15:59 +0000 (09:15 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 17 Nov 2010 09:15:59 +0000 (09:15 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20254 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-plugins/goto/admin/systems/services/kiosk/class_goKioskService.inc

index b07f09b7028351db805e32c5693d65e662156098..8b49ea30bd3623605a2325854b706235422700f7 100644 (file)
@@ -121,12 +121,13 @@ class goKioskService extends goService{
         if((isset($_POST['profileAdd']))&&(isset($_FILES['newProfile'])) && $this->acl_is_writeable("")){
             $file = $_FILES['newProfile'];
             if(!file_exists($this->baseDir.$file['name'])){
+                $filename = gosa_file_name($file['tmp_name']);
                 $tmp = array(
                         'url'     => "" ,
                         'name'    => $file['name'] ,
                         'initial' => FALSE,
-                        'tmp_name'=> $file['tmp_name'],
-                        'content' => file_get_contents($file['tmp_name']),
+                        'tmp_name'=> $filename,
+                        'content' => file_get_contents($filename),
                         'exists'  => TRUE);