Even i was trying implementing the same think but i couldnt make it. I used
image/jpeg
inputStream
filename="${filename}"
1024
But got an exception saying "Can not find a java.io.InputStream with the
name [inputStream] in the invocation stac
Jeromy Evans - Blue Sky Minds wrote:
>
>
> Hi Johnson, I think just need to read up a little more on Struts 2 as it
> seems you're trying to do too much yourself based on Struts1 experiences
> rather than let the framework do more of the routine work. Ian Roughly's
> book is a good place to
other than intended recipient. Sender does
not necessarily endorse content contained within this transmission.
> Date: Tue, 10 Feb 2009 07:43:52 -0800
> From: pie...@hotmail.com
> To: user@struts.apache.org
> Subject: Re: Struts 2 file upload
>
>
Lund wrote:
>
>
>
> newton.dave wrote:
>>
>> Lund wrote:
>>> I'm using Strurs 2.1.2 and the tag
>>> in
>>> the jsp page.
>>> My problem is that while the fileUpload appears to work most of the time
>>> I
>>> do get java.io.FileNotFoundException: on the .tmp file that Struts uses
>>> as
>>>
newton.dave wrote:
>
> Lund wrote:
>> I'm using Strurs 2.1.2 and the tag
>> in
>> the jsp page.
>> My problem is that while the fileUpload appears to work most of the time
>> I
>> do get java.io.FileNotFoundException: on the .tmp file that Struts uses
>> as
>> part of the process (prob 1 in 1
Lund wrote:
I'm using Strurs 2.1.2 and the tag in
the jsp page.
My problem is that while the fileUpload appears to work most of the time I
do get java.io.FileNotFoundException: on the .tmp file that Struts uses as
part of the process (prob 1 in 10 times). Once this happens of course the
whole
mgainty wrote:
>
> 2.0.11 FileUploadIntereptor.java
>
> ActionContext ac = invocation.getInvocationContext();
> HttpServletRequest request = (HttpServletRequest)
> ac.get(ServletActionContext.HTTP_REQUEST);
> HashMap map = request.getParameterMap();
> //for further information take a look at
>
Yes if the file size is OK everything is fine. At first we used the default
stack. Then we took the default and modified it by moving the
fileUploadInterceptor below the params interceptor so it would look
something like this:
interceptor-stack name="ourUploadStack"
interceptor-ref name="ex
The OP wrote:
>> we are trying to use file upload in Struts 2...
Martin wrote:
Struts 1.2.9
Doh!
org.apache.struts.chain.servlet.validateActionForm
where the validate method is declared as
protected ActionErrors validate(Context context,
ActionConfig actio
Rubbinio wrote:
Hi,
we are trying to use file upload in Struts 2 and run into the following
problem.
We have a form with multiple fields among which one is a file input field.
The user must complete the form and then select a file to upload. If the
file size is larger than what we specify in th
Struts 1.2.9
org.apache.struts.chain.servlet.validateActionForm
where the validate method is declared as
protected ActionErrors validate(Context context,
ActionConfig actionConfig,
ActionForm actionForm)
//reference the actionF
Johnson nickel wrote:
Hi Evans,
I digged in google examples in StreamResult. But, i can't
understand.
I want to display the images in browser Using StremResult.
Instead of ServletOutputStream out=
response.getOutputStream();
How can i use StreamResult.
Can u gi
: "Johnson nickel" <[EMAIL PROTECTED]>
To:
Sent: Friday, December 07, 2007 8:39 AM
Subject: Re: Struts 2 File upload to store the filedata
>
>
> Hi Evans,
>
> I digged in google examples in StreamResult. But, i can't
> understand.
> I want to displ
Hi Evans,
I digged in google examples in StreamResult. But, i can't
understand.
I want to display the images in browser Using StremResult.
Instead of ServletOutputStream out=
response.getOutputStream();
How can i use StreamResult.
Can u give some examples pgm??
Don't use ServletOutputStream within Struts2. Use a StreamResult instead:
http://struts.apache.org/2.0.11/docs/stream-result.html
In the example provided in the above link, inputName references a
property in your action that's an InputStream you need to create from
your data.
InputStream ge
Hi Evans,
I want to display the images in browser from the database.
I have added my code.It throws null pointer Exception.
In my action, i have implements
ServletRequestAware,ServletResponseAware interface. I want to
know if ServletOutputStream
Johnson nickel wrote:
Hi Jeromy Evans,
Thanks for your reply. I would like to insert the images into
my
Databases. For that, i'm using byte[] array.
In Struts 1.3,
I used FormFile class. From this class i got the method
getFileData();
Hi Jeromy Evans,
Thanks for your reply. I would like to insert the images into
my
Databases. For that, i'm using byte[] array.
In Struts 1.3,
I used FormFile class. From this class i got the method
getFileData();
In my db, ps.setBytes(1,fi
Johnson nickel wrote:
Hi everyone,
I am using Struts 2 and using tag to upload a file.
But I get that file as a 'File' object in my action class and using
getFileName() on that File object returns me some arbitrary value (something
like upload__5b41f107_1127b4befe0__8000_.tmp). I want t
19 matches
Mail list logo