|
@@ -51,14 +51,18 @@ class Qiniu extends Core implements Config
|
|
|
public function file()
|
|
|
{
|
|
|
if ($this->base64 && isset($this->data['local'])) {
|
|
|
- $this->data['local'] = str_replace(Dever::data() . 'upload/', '', $this->data['local']);
|
|
|
$this->file = $this->data['local'] . $this->name . $this->ext;
|
|
|
} else {
|
|
|
$this->file = $this->path . $this->name . $this->ext;
|
|
|
}
|
|
|
|
|
|
$this->output['file'] = $this->file;
|
|
|
- $this->output['url'] = $this->host . $this->file;
|
|
|
+ if (strstr($this->file, 'http')) {
|
|
|
+ $this->output['url'] = $this->file;
|
|
|
+ } else {
|
|
|
+ $this->output['url'] = $this->host . $this->file;
|
|
|
+ }
|
|
|
+
|
|
|
//$this->output['url'] = '{uploadYun}' . $this->file;
|
|
|
return $this->output['file'];
|
|
|
}
|