You can implement the ServletContextAware interface in your action,
and Struts will set the ServletContext which has a "getPath" method,
or something like that.
musachy
On Fri, Feb 6, 2009 at 9:03 AM, Security Management
wrote:
> I have an action that returns an image, and the getImageStream met
Using a FileInputStream like that won't work if the war is packaged.
Take a look at the getResourceAsStream method in the ServletContext
interface instead.
Nils-H
On Fri, Feb 6, 2009 at 3:03 PM, Security Management
wrote:
> I have an action that returns an image, and the getImageStream method
>
I have an action that returns an image, and the getImageStream method
returns the stream associated with the blob in the database that I'm
pulling.
That works great, and displays/exports the image exactly like I want to.
However, there are cases where there is no image, and I want to display a
"N
3 matches
Mail list logo