send a content-disposition header for shared files, so browser knows how to name downloaded file

This commit is contained in:
Ralf Becker 2014-12-14 12:33:42 +00:00
parent 46be95a854
commit ef90797b7e

View File

@ -221,6 +221,11 @@ class egw_sharing
// or if no filemanager installed (WebDAV has own autoindex)
!file_exists(__DIR__.'/../../filemanager/inc/class.filemanager_ui.inc.php'))
{
// send a content-disposition header, so browser knows how to name downloaded file
if (!egw_vfs::is_dir($this->share['share_path']))
{
html::content_disposition_header(egw_vfs::basename($this->share['share_path']), false);
}
//$GLOBALS['egw']->session->commit_session();
$webdav_server = new vfs_webdav_server();
$webdav_server->ServeRequest('/'.$this->share['share_token']);