mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 06:30:59 +01:00
fall back to Api\MimeMagic::filename2mime, if mime_content_type function is not available
This commit is contained in:
parent
087cff7f25
commit
3bc0dc60d6
@ -183,7 +183,14 @@ function read_thumbnail($src)
|
||||
list(, $path) = explode($GLOBALS['egw_info']['server']['webserver_url'],
|
||||
Api\Image::find($app, $icon), 2);
|
||||
$dst = EGW_SERVER_ROOT.$path;
|
||||
$output_mime = mime_content_type($dst);
|
||||
if (function_exist('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