From c3cd65d7be93c4083a45b79ce3092a3c58b8728a Mon Sep 17 00:00:00 2001 From: Fabio Bas Date: Wed, 6 Apr 2016 21:38:46 +0200 Subject: Possibly fix #581 --- HISTORY | 1 + framework/Web/UI/ActiveControls/TActiveFileUpload.php | 1 + framework/Web/UI/WebControls/TFileUpload.php | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/HISTORY b/HISTORY index af5358f1..ea1c8892 100644 --- a/HISTORY +++ b/HISTORY @@ -2,6 +2,7 @@ Version 3.3.1 XXX XX, 2016 BUG: Issue #540 - Fix TActiveFileUpload on IE11 (ctrlaltca) BUG: Issue #574 - Fix TActiveCustomValidator validation after error (ctrlaltca) +BUG: Issue #581 - TActiveFileUpload loses track of LocalName for a moment (emkael) BUG: Issue #582 - Prado autoloader breaks class_exists conditionals (ctrlaltca) BUG: TJuiAutoComplete: fix parsing of suggestions (ctrlaltca) BUG: Fix callback for controls with PostState=false (ctrlaltca) diff --git a/framework/Web/UI/ActiveControls/TActiveFileUpload.php b/framework/Web/UI/ActiveControls/TActiveFileUpload.php index 7f11115a..04350411 100755 --- a/framework/Web/UI/ActiveControls/TActiveFileUpload.php +++ b/framework/Web/UI/ActiveControls/TActiveFileUpload.php @@ -101,6 +101,7 @@ class TActiveFileUpload extends TFileUpload implements IActiveControl, ICallback // save the file so that it will persist past the end of this return. $localName = str_replace('\\', '/', tempnam(Prado::getPathOfNamespace($this->getTempPath()),'')); parent::saveAs($localName); + $this->_localName = $localName; $params = new TActiveFileUploadCallbackParams; $params->localName = $localName; diff --git a/framework/Web/UI/WebControls/TFileUpload.php b/framework/Web/UI/WebControls/TFileUpload.php index 142543c7..60f46701 100644 --- a/framework/Web/UI/WebControls/TFileUpload.php +++ b/framework/Web/UI/WebControls/TFileUpload.php @@ -47,7 +47,7 @@ class TFileUpload extends TWebControl implements IPostBackDataHandler, IValidata /** * @var string the name of the temporary file storing the uploaded file */ - private $_localName=''; + protected $_localName=''; /** * @var string the uploaded file mime type */ -- cgit v1.2.3