Also, is there a particular reason why the data needs to go in the session
instead of just adding a getImage() method to your action that will return
the data that you need?

-Jesse


|------------>
| From:      |
|------------>
  
>--------------------------------------------------------------------------------------------------------------------------------------------------|
  |Maurizio Cucchiara <maurizio.cucchi...@gmail.com>                            
                                                                     |
  
>--------------------------------------------------------------------------------------------------------------------------------------------------|
|------------>
| To:        |
|------------>
  
>--------------------------------------------------------------------------------------------------------------------------------------------------|
  |Struts Users Mailing List <user@struts.apache.org>, angryg...@gmail.com      
                                                                     |
  
>--------------------------------------------------------------------------------------------------------------------------------------------------|
|------------>
| Date:      |
|------------>
  
>--------------------------------------------------------------------------------------------------------------------------------------------------|
  |11/15/2010 12:41 PM                                                          
                                                                     |
  
>--------------------------------------------------------------------------------------------------------------------------------------------------|
|------------>
| Subject:   |
|------------>
  
>--------------------------------------------------------------------------------------------------------------------------------------------------|
  |Re: Putting an Image (in Bytes) on the session                               
                                                                     |
  
>--------------------------------------------------------------------------------------------------------------------------------------------------|





You're right, it smells like a wrong approach :). Storing image's bytes is
a
space consuming practice.

Anyway, Could you explain what do you need?


2010/11/15 Greg Akins <angryg...@gmail.com>

> This seems like maybe I'm approaching it wrong.. but wondering if it's
> possible.
>
> I'm wondering if I can put an image, in the form of a byte array, or
> stream, that I can read with either a struts tag, jstl, or el
>
> Thinking in my action
>
> session.put("image", image.getBytes());
>
> and in the .jsp
>
> ${image}
>
> Thoughts on this, or other ways to do something similar?
>
> --
> Greg Akins
>
> http://insomnia-consulting.org
> http://www.pghcodingdojo.org
> http://pittjug.dev.java.net
> http://twitter.com/akinsgre
> http://www.linkedin.com/in/akinsgre
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
> For additional commands, e-mail: user-h...@struts.apache.org
>
>


--
Maurizio Cucchiara


Reply via email to