Found this doc on Google, it might help you :

http://balusc.blogspot.com/2007/04/imageservlet.html#ImageServletServingFromDatabase

On 20 nov, 05:09, java-dev <sehgal....@gmail.com> wrote:
> hi all,
>
> I need some help with images in appengine using java. Now I have
> sucessfully uploaded an image file and stored it to the datastore. I
> am also able to read back the stored image (as a byte[] array). Now
> the issue is, how do I display this image in my jsp page?
>
> ***************************************************************
>
> //gets the image file Object  from the read data d
> ImageFile f = d.getImg();
>
> //gets the byte array of this image
> byte[] imb = f.getImg();
>
> //futile attempt to display this image
> for(int i=0; i<imb.length; i++)
> out.println(imb[i]);
>
> ***************************************************************
> The above code displays the raw bytes on the jsp page....How can I get
> this to display the image itself?
>
> Any help would be greatly appreciated..
>
> Thanks.

--

You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=.


Reply via email to