diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2008-01-10 22:42:41 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2008-01-10 22:42:41 +0000 |
commit | 941f9bf3dd3bfbbb575cd5f56d52a52fdf173eba (patch) | |
tree | 6f8e23e74a755f9370cea6fe53a3b5fb5d809ed4 /app/controllers/documents_controller.rb | |
parent | a39f655a7c86fab775e725505f262692ced2c2ca (diff) | |
download | redmine-941f9bf3dd3bfbbb575cd5f56d52a52fdf173eba.tar.gz redmine-941f9bf3dd3bfbbb575cd5f56d52a52fdf173eba.zip |
Non-ascii attachement filename fix for IE.
git-svn-id: http://redmine.rubyforge.org/svn/trunk@1053 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/controllers/documents_controller.rb')
-rw-r--r-- | app/controllers/documents_controller.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/controllers/documents_controller.rb b/app/controllers/documents_controller.rb index b37a8371a..93f25c495 100644 --- a/app/controllers/documents_controller.rb +++ b/app/controllers/documents_controller.rb @@ -67,7 +67,8 @@ class DocumentsController < ApplicationController def download @attachment = @document.attachments.find(params[:attachment_id]) @attachment.increment_download - send_file @attachment.diskfile, :filename => @attachment.filename, :type => @attachment.content_type + send_file @attachment.diskfile, :filename => filename_for_content_disposition(@attachment.filename), + :type => @attachment.content_type rescue render_404 end |