X-Git-Url: https://git.p6c8.net/jirafeau_mojo42.git/blobdiff_plain/c5187160be16af5c5574a020ff83e7da586c4338..6ceeb5ff538f89833b1ab3f2ecd3cf89a3d8e17e:/file.php?ds=sidebyside diff --git a/file.php b/file.php index d01bee6..400cb73 100644 --- a/file.php +++ b/file.php @@ -119,7 +119,7 @@ if (isset ($_GET['h']) && !empty ($_GET['h'])) header ('Content-Length: ' . $link['file_size']); header ('Content-Type: ' . $link['mime_type']); - if (!jirafeau_is_viewable ($link['mime_type'])) + if (!jirafeau_is_viewable ($link['mime_type']) || !$cfg['preview']) { header ('Content-Disposition: attachment; filename="' . $link['file_name'] . '"');