From b208d74e628124abf1560fd80a581520995ce6c6 Mon Sep 17 00:00:00 2001 From: Mike Rylander Date: Mon, 2 Apr 2018 16:09:12 -0400 Subject: [PATCH] LP#1760223: Update HTTP headers to follow standard In the olden days, some browsers didn't understand the "attachment" content disposition. They only understood "inline" but would let the user save a file if a filename was provided. However, in these modern days, relevant browsers all do the right thing and know about both flavors of content disposition, so we, too, must change with the times and support the letter of the standard. This commit fixes downloading of MARCXML from the Exporter module. Signed-off-by: Mike Rylander Signed-off-by: Jane Sandberg Signed-off-by: Cesar Velez Signed-off-by: Galen Charlton --- Open-ILS/src/perlmods/lib/OpenILS/WWW/Exporter.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/Exporter.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/Exporter.pm index bf2fa367ca..8508ab6ede 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/Exporter.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/Exporter.pm @@ -180,7 +180,7 @@ sub handler { } - $r->headers_out->set("Content-Disposition" => "inline; filename=$filename"); + $r->headers_out->set("Content-Disposition" => "attachment; filename=$filename"); if (uc($format) eq 'XML') { $r->content_type('application/xml'); -- 2.11.0