Hello,
I would to display a message on the jsp page saying to the user that the
file he tried to upload is too big. I did the same that in the example.
In my form:
Boolean maxLengthExceeded = (Boolean)
request.getAttribute(MultipartRequestHandler.ATTRIBUTE_MAX_LENGTH_EXCEEDED);
if ((maxLengthExceeded != null) && (maxLengthExceeded.booleanValue())) {
errors.add(ERROR_PROPERTY_MAX_LENGTH_EXCEEDED, new
ActionError(MAX_LENGTH));
}
in my JSP page:
<font color="#CC6600"><b><html:errors/></b></font>
<logic:present name="maxlength.error" scope="request">
<font color="#CC6600"><b><bean:message name="maxlength.error" property="key"
/><b></font>
</logic:present>
<logic:notPresent name="maxlength.error" scope="request">
Note that the maximum allowed size of an uploaded file for this application is one
megabytes.
</logic:notPresent>
When I execute, it always display the second phrase.
What is wrong? to precise: I did not use a JSP directly, but a tiles page.
Thanks for your help,
Ludo.
This message and any attachments (the "message") is intended solely for the addressees
and is confidential.
If you receive this message in error, please delete it and immediately notify the
sender. Any use not in accord with
its purpose, any dissemination or disclosure, either whole or partial, is prohibited
except formal approval.
The internet can not guarantee the integrity of this message. BNP PARIBAS (and its
subsidiaries) shall (will) not
therefore be liable for the message if modified.
---------------------------------------------
Ce message et toutes les pieces jointes (ci-apres le "message") sont etablis a
l'intention exclusive de ses
destinataires et sont confidentiels. Si vous recevez ce message par erreur, merci de
le detruire et d'en avertir
immediatement l'expediteur. Toute utilisation de ce message non conforme a sa
destination, toute diffusion
ou toute publication, totale ou partielle, est interdite, sauf autorisation expresse.
L'internet ne permettant pas
d'assurer l'integrite de ce message, BNP PARIBAS (et ses filiales) decline(nt) toute
responsabilite au titre de ce
message, dans l'hypothese ou il aurait ete modifie.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]