From 7b6ec52d5e6ec69f6a7e025a313820129ac8c7e6 Mon Sep 17 00:00:00 2001 From: Skylar Ittner Date: Fri, 2 Apr 2021 15:31:39 -0600 Subject: [PATCH] Add Content-Disposition filename header --- public/file.php | 1 + 1 file changed, 1 insertion(+) diff --git a/public/file.php b/public/file.php index eaf3a64..fdd4677 100644 --- a/public/file.php +++ b/public/file.php @@ -56,6 +56,7 @@ $ts = gmdate("D, d M Y H:i:s", time() + $seconds_to_cache) . " GMT"; header("Expires: $ts"); header("Pragma: cache"); header("Cache-Control: max-age=$seconds_to_cache"); +header("Content-Disposition: filename=\"" . pathinfo($filepath)['basename'] . "\""); ob_end_flush();