diff --git a/FileUpload.php b/FileUpload.php index a3a5133..d212766 100644 --- a/FileUpload.php +++ b/FileUpload.php @@ -10,4 +10,9 @@ class FileUpload extends FormField { $this->value=$_FILES[$name]['name']; $this->file=$_FILES[$name]['tmp_name']; } + + public function getTmpPath() { + if ($this->error > 0) throw new UploadException("Upload failure", $this->error); + return $this->file; + } }