Skip to content
This repository was archived by the owner on Jul 29, 2022. It is now read-only.

Commit 8830bcc

Browse files
authored
Merge pull request #71 from bmiro/download_utf8_filename
Removed unnecessary UTF-8. Added fix in other case.
2 parents 490bcc6 + fc8148a commit 8830bcc

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

nginx/nginx.conf

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -76,9 +76,9 @@ http {
7676
add_header 'Content-Disposition' 'attachment'; # THUMBOR_ALLOW_CONTENT_DISPOSITION
7777
} # THUMBOR_ALLOW_CONTENT_DISPOSITION
7878

79-
if ($args ~* "download_filename"){ # THUMBOR_ALLOW_CONTENT_DISPOSITION
80-
add_header 'Content-Disposition' 'attachment; filename="$arg_download_filename"'; # THUMBOR_ALLOW_CONTENT_DISPOSITION
81-
} # THUMBOR_ALLOW_CONTENT_DISPOSITION
79+
if ($args ~* "download_filename"){ # THUMBOR_ALLOW_CONTENT_DISPOSITION
80+
add_header 'Content-Disposition' 'attachment; filename="$arg_download_filename"; filename*="$arg_download_filename"'; # THUMBOR_ALLOW_CONTENT_DISPOSITION
81+
} # THUMBOR_ALLOW_CONTENT_DISPOSITION
8282
}
8383

8484
location = /healthcheck {
@@ -95,9 +95,9 @@ http {
9595
add_header 'Content-Disposition' 'attachment'; # THUMBOR_ALLOW_CONTENT_DISPOSITION
9696
} # THUMBOR_ALLOW_CONTENT_DISPOSITION
9797

98-
if ($args ~* "download_filename"){ # THUMBOR_ALLOW_CONTENT_DISPOSITION
99-
add_header 'Content-Disposition' 'attachment; filename="$arg_download_filename"; filename*=UTF-8"$arg_download_filename"'; # THUMBOR_ALLOW_CONTENT_DISPOSITION
100-
} # THUMBOR_ALLOW_CONTENT_DISPOSITION
98+
if ($args ~* "download_filename"){ # THUMBOR_ALLOW_CONTENT_DISPOSITION
99+
add_header 'Content-Disposition' 'attachment; filename="$arg_download_filename"; filename*="$arg_download_filename"'; # THUMBOR_ALLOW_CONTENT_DISPOSITION
100+
} # THUMBOR_ALLOW_CONTENT_DISPOSITION
101101
}
102102

103103
location ~ /\.ht { deny all; access_log off; error_log off; }

0 commit comments

Comments
 (0)