|
@@ -209,7 +209,12 @@ class Core
|
|
|
header('Content-type: text/json; charset=utf-8');
|
|
|
$path = Dever::path($this->base, 'tmp/');
|
|
|
|
|
|
- $this->ext = '.' . pathinfo($name, PATHINFO_EXTENSION);
|
|
|
+ $ext = $name;
|
|
|
+ if (strstr($name, '?')) {
|
|
|
+ $temp = explode('?', $ext);
|
|
|
+ $ext = $temp[0];
|
|
|
+ }
|
|
|
+ $this->ext = '.' . pathinfo($ext, PATHINFO_EXTENSION);
|
|
|
$this->data['file']['name'] = 'Tmp' . sha1($name);
|
|
|
$this->data['file']['tmp_name'] = $path . $this->data['file']['name'];
|
|
|
|