From c9e71b81d9ae66446463ad46c4b558cd2fd5994f Mon Sep 17 00:00:00 2001 From: hickert Date: Wed, 6 Sep 2006 07:08:26 +0000 Subject: [PATCH] Templates were broken when downloaded git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@4602 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/fai/class_faiTemplateEntry.inc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/admin/fai/class_faiTemplateEntry.inc b/plugins/admin/fai/class_faiTemplateEntry.inc index 57eee4124..29267dd92 100644 --- a/plugins/admin/fai/class_faiTemplateEntry.inc +++ b/plugins/admin/fai/class_faiTemplateEntry.inc @@ -52,7 +52,7 @@ class faiTemplateEntry extends plugin $this->user = explode( '.', $this->FAIowner ); $this->group = $this->user[1]; $this->user = $this->user[0]; - $_SESSION['binary'] = $this->FAItemplateFile; + $_SESSION['binary'] = stripslashes($this->FAItemplateFile); $_SESSION['binarytype'] = 'octet-stream'; $_SESSION['binaryfile'] = basename( $this->FAItemplatePath ); @@ -72,14 +72,14 @@ class faiTemplateEntry extends plugin if(isset($_POST['TmpFileUpload'])){ if($str=file_get_contents($_FILES['FAItemplateFile']['tmp_name'])){ - $this->FAItemplateFile = $str; + $this->FAItemplateFile = addslashes($str); /* If we don't have a filename set it from upload filename. */ if( 0 == strlen( $this->FAItemplatePath )){ $this->FAItemplatePath = $_FILES['FAItemplateFile']['name']; } - $_SESSION['binary'] = $this->FAItemplateFile; + $_SESSION['binary'] = stripslashes($this->FAItemplateFile); $_SESSION['binarytype'] = 'octet-stream'; $_SESSION['binaryfile'] = basename( $this->FAItemplatePath ); } -- 2.30.2