Hi,

Anybody got the idea of restricting the upload file size without user
actually sending large file to the server's temporary directory?

I have known that in struts web.xml configuration file that there is a
init parameter to restrict the uploaded file size named 'maxFileSize'
something like that. It seems that it indeed works for that purpose
correctly, but as long as the user tries to upload an file with an
exceeding file size the ActionServlet throws ServletException, there is
no way to capture it as I know so far. The possible solution that I can
only think out currently is to re-write the 'process(...)' method in
ActionServlet which accommodates my needs. Is there any better solution
for my purpose?

Thanks in advance.

Michael

Reply via email to