Hi Eric,
This isn't really something that should be included directly into HttpClient as HttpClient isn't intended to care about the actual content it sends and receives but just takes care of the actual HTTP protocol side of things. Adding auto-mime type detection would mean we'd also have to provide a way to configure the default mime-types etc, in other words it opens a whole can of worms.


However, this would be an excellent submission to the HttpClient contrib package, particularly if we refactor it so that instead of being a patch it's a complete class that extends FilePart to add the functionality, then it could easily be used without any changes to HttpClient. Would you be happy with that course of action? If so, would you like to adapt the patch into a standalone class yourself or would you like me to take a crack at it? I don't mind either way.

Thanks a lot for the contribution, it will definitely be useful to a number of people.

Regards,

Adrian Sutton.

On Thursday, June 19, 2003, at 12:46 PM, Eric M Devlin wrote:

Hey,
This is a patch which will determine the content type if null based on
file extension. I used the file extension mapping from
$TOMCAT_HOME/conf/web.xml. As a side note, I'm having trouble sending gif
files. Any thoughts or a kick in the right direction would be helpful.
Thanks and Hope It Helps
Eric
<contentTypeByExtension.txt>------------------------------------------- --------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to