mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-02-22 21:21:04 +01:00
fix thumbnail.php to deal with icons from the vfs
This commit is contained in:
parent
a9b9cfce08
commit
bb923b33e5
@ -175,17 +175,9 @@ function read_thumbnail($src)
|
||||
list($app, $icon) = explode('/', Vfs::mime_icon($mime), 2);
|
||||
list(, $path) = explode($GLOBALS['egw_info']['server']['webserver_url'],
|
||||
Api\Image::find($app, $icon), 2);
|
||||
$dst = EGW_SERVER_ROOT.$path;
|
||||
$dst = str_starts_with($path, '/webdav.php/') ? Api\Vfs::PREFIX.substr($path, 11) : EGW_SERVER_ROOT.$path;
|
||||
$_GET['thsize'] = 22;
|
||||
return read_thumbnail($dst);
|
||||
if (function_exists('mime_content_type'))
|
||||
{
|
||||
$output_mime = mime_content_type($dst);
|
||||
}
|
||||
else
|
||||
{
|
||||
$output_mime = Api\MimeMagic::filename2mime($dst);
|
||||
}
|
||||
}
|
||||
|
||||
if ($dst)
|
||||
|
Loading…
Reference in New Issue
Block a user