Solved

showing a jpeg from a byte stream

Posted on 2006-10-23
3
283 Views
Last Modified: 2008-01-09
Hi experts,

I have been putting jpeg byte streams in BLOBs in my mySQL database...

and now i'm wondering if maybe i should have done some sort of file saving technique instead...

Given that I have access to Java servlets, and i am making an AJAX website,

what is the best way that i can show these images to the website user?
(eg. make temporary files out of the byte streams, and send back the link via XML?)
Thanks
Dan
0
Comment
Question by:dbrownell83
  • 2
3 Comments
 
LVL 9

Accepted Solution

by:
alkisg earned 400 total points
ID: 17791452
<img src="http://myserver/getimage.jsp?index=8">
where getimage.jsp modifies the http headers so that it directly sends an image without writing it to the file system...
0
 
LVL 1

Author Comment

by:dbrownell83
ID: 17791540
cool, MIME types.  i forgot about those.  thank you
0
 
LVL 9

Expert Comment

by:alkisg
ID: 17793674
You're welcome!
0

Featured Post

Back Up Your Microsoft Windows Server®

Back up all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article shows how to create and access 2-dimensional arrays in JavaScript.  It includes a tutorial in case you are just trying to "get your head wrapped around" the concept and we'll also look at some useful tips for more advanced programmers. …
The task A number given should be formatted for easy reading by separating digits into triads. Format must be made inline via JavaScript, i.e., frameworks / functions are not welcome. So let’s take a number like this “12345678.91¿ and format i…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question