小胡
7 months ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
6 additions and
1 deletions
-
core/class/io/io_dzz.php
|
|
@ -309,7 +309,12 @@ class io_dzz extends io_api |
|
|
|
$quality = 80; |
|
|
|
$imgcachePath = 'imgcache/'; |
|
|
|
$cachepath = str_replace('//', '/', str_replace(':', '/', $data['attachment'] ? $data['attachment'] : $data['path'])); |
|
|
|
$target = $imgcachePath . ($cachepath) . '.' . $width . '_' . $height . '_'.$thumbtype.'.jpeg'; |
|
|
|
if ($data['ext'] == 'png' || $data['ext'] == 'PNG') { |
|
|
|
$targetext = '.png'; |
|
|
|
} else { |
|
|
|
$targetext = '.jpeg'; |
|
|
|
} |
|
|
|
$target = $imgcachePath . ($cachepath) . '.' . $width . '_' . $height . '_'.$thumbtype.$targetext; |
|
|
|
if (!$original && $enable_cache && @getimagesize($_G['setting']['attachdir'] . './' . $target)) { |
|
|
|
if ($returnurl) return $_G['setting']['attachurl'] . '/' . $target; |
|
|
|
$file = $_G['setting']['attachdir'] . './' . $target; |
|
|
|