diff --git a/modules/Vtiger/helpers/ShowFile.php b/modules/Vtiger/helpers/ShowFile.php index dd3d1ee070ed757c558915a12dee64aaf5e8a129..a65361d8996dd043ddcaf7b40ad2855b727212a3 100644 --- a/modules/Vtiger/helpers/ShowFile.php +++ b/modules/Vtiger/helpers/ShowFile.php @@ -67,6 +67,7 @@ class Vtiger_ShowFile_Helper { $handle = fopen($finalFilePath, "rb"); $contents = fread($handle, filesize($finalFilePath)); fclose($handle); + //added since other than image files we need file names, other wise it downloads with public.php extension which is treated as dangerous if($sanitizedFileName) { header("Content-Disposition: attachment; filename=\"$sanitizedFileName\"");