This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Servlets and the fly likes Can I change the response mime type midway? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Can I change the response mime type midway?" Watch "Can I change the response mime type midway?" New topic
Author

Can I change the response mime type midway?

utsav gupta
Ranch Hand

Joined: Mar 19, 2009
Posts: 57
Hi

I wish to send a jpeg file to the browser followed by some text. How can i achieve that? Do i have to change the content type after writing the jpeg file in output stream to plain text?

Thanks
utsav.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60783
    
  65

No.

One request == one response.

What are you actually trying to accomplish?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Can I change the response mime type midway?
 
Similar Threads
overlay jpeg with text
Get File Type
type="file"
How to apply the filter for file selection
Display image in jsp