Feature #2209

MIME type support for repository Entries

Added by Vincent Castellano almost 14 years ago. Updated over 9 years ago.

Status:NewStart date:2008-11-17
Priority:NormalDue date:
Assignee:-% Done:


Target version:-


I didn't like that images didn't just load in the browser that were in a repository, and felt there should be some MIME support, so I gave it a shot. I think it works for any files (with MIME type or not, which just defaults to the old behavior). I don't know the Redmine code base well, and I'm not a Ruby programmer, so it was a quick attempt.

MimeType.patch Magnifier (1.02 KB) Vincent Castellano, 2008-11-17 20:56

MimeType.patch Magnifier - Cleaned up a bit. (1016 Bytes) Vincent Castellano, 2008-11-17 20:57

dl_repo_files_with_MimeType_r2823.patch Magnifier (944 Bytes) Chris Grieger, 2009-07-18 18:16

Related issues

Related to Redmine - Feature #4477: Use mime types in downloading from repository Closed 2009-12-23
Related to Redmine - Defect #6256: Redmine considers non ASCII and UTF-16 text files as bina... Closed 2010-08-31
Related to Redmine - Patch #3770: text/html documents force currently firefox to open downl... New 2009-08-23
Related to Redmine - Feature #6374: File raw view mode Closed 2010-09-12
Related to Redmine - Feature #5055: Set mime-type in response when downloading repository files Closed 2010-03-11
Related to Redmine - Defect #6370: UTF-8 BOM only partially hidden Closed 2010-09-12
Related to Redmine - Feature #4577: convert text file attached an issue to utf-8. Closed 2010-01-14


#2 Updated by Chris Cummer almost 14 years ago

A slight fix: I think line #125 should read:

send_data @content, :filename => fn, :type => type, :disposition => 'inline'

rather than:

send_data @content, :filename => fn, :type => type, => 'inline'

#3 Updated by Patrick Hurrelmann almost 14 years ago

+1, I like it very much. It keeps annoying me that files won't open in the browser even if the mime-type in the repository are set properly.

#4 Updated by Ammler _ about 13 years ago


#5 Updated by Chris Grieger about 13 years ago

Patch for the current #2823 revision.

#6 Updated by Toshi MARUYAMA over 11 years ago

  • Category set to SCM

#7 Updated by Toshi MARUYAMA over 11 years ago

  • Status changed from New to 7
  • Assignee set to Toshi MARUYAMA

#8 Updated by Toshi MARUYAMA over 11 years ago

  • Tracker changed from Patch to Feature

#9 Updated by Toshi MARUYAMA over 11 years ago

  • % Done changed from 0 to 70

As I described at #4477, I implemented this feature at r5210.
I don't know whether "inline" needs or not.

#10 Updated by Jean-Philippe Lang over 9 years ago

  • Status changed from 7 to New

#11 Updated by Toshi MARUYAMA over 9 years ago

  • Assignee deleted (Toshi MARUYAMA)

Also available in: Atom PDF