summaryrefslogtreecommitdiff
path: root/framework/Web
diff options
context:
space:
mode:
Diffstat (limited to 'framework/Web')
-rwxr-xr-xframework/Web/UI/ActiveControls/TActiveFileUpload.php7
1 files changed, 2 insertions, 5 deletions
diff --git a/framework/Web/UI/ActiveControls/TActiveFileUpload.php b/framework/Web/UI/ActiveControls/TActiveFileUpload.php
index b478e119..7f11115a 100755
--- a/framework/Web/UI/ActiveControls/TActiveFileUpload.php
+++ b/framework/Web/UI/ActiveControls/TActiveFileUpload.php
@@ -102,12 +102,9 @@ class TActiveFileUpload extends TFileUpload implements IActiveControl, ICallback
$localName = str_replace('\\', '/', tempnam(Prado::getPathOfNamespace($this->getTempPath()),''));
parent::saveAs($localName);
- $filename=addslashes($this->getFileName());
-
-
$params = new TActiveFileUploadCallbackParams;
$params->localName = $localName;
- $params->fileName = $filename;
+ $params->fileName = addslashes($this->getFileName());
$params->fileSize = $this->getFileSize();
$params->fileType = $this->getFileType();
$params->errorCode = $this->getErrorCode();
@@ -198,7 +195,7 @@ EOS;
$params = $this->popParamsByToken($cp->callbackToken);
- $_FILES[$key]['name'] = $params->fileName;
+ $_FILES[$key]['name'] = stripslashes($params->fileName);
$_FILES[$key]['size'] = intval($params->fileSize);
$_FILES[$key]['type'] = $params->fileType;
$_FILES[$key]['error'] = intval($params->errorCode);