Skip to content

Commit

Permalink
fix FileRenderer to send the right Content-Disposition - see #102
Browse files Browse the repository at this point in the history
  • Loading branch information
mikespub committed Sep 2, 2024
1 parent 8647d12 commit bfe960a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ x.x.x - TODO
2.8.x - 2024xxxx
* ...

2.8.1 - 20240902 Fix download filenames
* Fix FileRenderer to send the right Content-Disposition - see issue #102 by @Chirishman

2.8.0 - 20240901 Support 'kepubify' tool for Kobo
* Add FileRenderer class to send files + use sendHeaders
* Fix Zipper to allow unicode chars in file names
Expand Down
2 changes: 1 addition & 1 deletion lib/Input/Config.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
class Config
{
public const VERSION = '2.8.0';
public const VERSION = '2.8.1';
public const ENDPOINT = [
"index" => "index.php",
"feed" => "feed.php",
Expand Down
2 changes: 1 addition & 1 deletion lib/Output/FileRenderer.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ public static function sendFile($filepath, $filename = null, $mimetype = null, $
} elseif (empty($filename)) {
header('Content-Disposition: inline');
} else {
header('Content-Disposition: attachment; filepath="' . basename($filename) . '"');
header('Content-Disposition: attachment; filename="' . basename($filename) . '"');
}

// @todo clean up nginx x_accel_redirect
Expand Down

0 comments on commit bfe960a

Please sign in to comment.