• Post Reply Bookmark Topic Watch Topic
  • New Topic

File Upload  RSS feed

 
Nagarajan Krishnamurthy
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need to write a servlet that receives a audio file and send that as mail.
Without using any third party implementations(like apache..)how do i achieve this.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You would have to dig into the HTTP spec to learn all about multipart requests for starters. Then you would have to implement a request handler that can intercept a multipart request, parse it, and write the binary data sent within to a file (or if it's small enough, store it in memory).

Then you would need to learn JavaMail (it's a separate API but it's put out by Sun).
[ August 09, 2007: Message edited by: Ben Souther ]
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!