Skip to content
Snippets Groups Projects
Commit a7d58587 authored by Dries Buytaert's avatar Dries Buytaert
Browse files

- Patch #103164 by davea and RobRoy: made downloads work on IE6. Send correct headers.

parent 67774634
No related branches found
No related tags found
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
...@@ -265,12 +265,10 @@ function upload_file_download($file) { ...@@ -265,12 +265,10 @@ function upload_file_download($file) {
if (user_access('view uploaded files')) { if (user_access('view uploaded files')) {
$node = node_load($file->nid); $node = node_load($file->nid);
if (node_access('view', $node)) { if (node_access('view', $node)) {
$name = mime_header_encode($file->filename);
$type = mime_header_encode($file->filemime); $type = mime_header_encode($file->filemime);
return array( return array(
'Content-Type: '. $type .'; name='. $name, 'Content-Type: '. $type,
'Content-Length: '. $file->filesize, 'Content-Length: '. $file->filesize,
'Cache-Control: private'
); );
} }
else { else {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment