Bug 27597 - <mt:attach>: set Content-Type header
Summary: <mt:attach>: set Content-Type header
Alias: None
Product: Taglibs
Classification: Unclassified
Component: Mailer Taglib (show other bugs)
Version: unspecified
Hardware: All All
: P3 normal (vote)
Target Milestone: ---
Assignee: Tomcat Developers Mailing List
Depends on:
Reported: 2004-03-11 11:06 UTC by Marc Guillemot
Modified: 2009-11-29 19:39 UTC (History)
0 users

Path to set the Content-Type of an attached file (426 bytes, patch)
2004-03-11 11:07 UTC, Marc Guillemot
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Marc Guillemot 2004-03-11 11:06:06 UTC
The <mt:attach> tag attaches files without specifying any Content-Type
information. This causes pdf files for instance to be sent as
"application/octet-stream" instead of "application/pdf".

It would be wise to ask the servlet container for the content type of the file. 

Further the tag could be refactored to give the possibility to use the "type"
attribute to set explicitely the content type to use. Currently this attribute
is only allowed for content specified in the body of the tag.
Comment 1 Marc Guillemot 2004-03-11 11:07:13 UTC
Created attachment 10755 [details]
Path to set the Content-Type of an attached file
Comment 2 Henri Yandell 2009-11-29 19:39:59 UTC
Resolving. Taglib has been retired.