On 10/27/2003 09:59 AM Keld Hansen wrote:
Let me elaborate a little:

As I understand it the Validator uses the ActionErrors queue. This
means that I'll have to code this in my jsp-page:

<html:messages id="error" message="false"> <BR><bean:write
name="error"/> </html:messages>

If I use the ActionMessages queue for my own validation - or error
handling in general - in my Action classes, then I'll also have to
code this in my jsp-pages:

<html:messages id="error" message="true"> <BR><bean:write
name="error"/> </html:messages>

So the net result is that my jps-pages becomes more clumsy.

My question is really: is it possible to direct messages from the
Validator to the ActionMessages queue?

If not: how is it then possible to deprecate the ActionErrors queue?

This works to display the Validator messages and errors from the Actions if you save them like request.setAttribute(Globals.MESSAGE_KEY, messages)

<html:messages id="errorMsgs"
          message="true"
         property="${GLOBAL_ERROR}"
           header="errors.header"
           footer="errors.footer">
  <c:out value="${errorMsgs}" />
</html:messages>

I'm afraid I don't remember the finer details but this will show both yours and Validator's errors.

Adam
--
struts 1.1 + tomcat 5.0.12 + java 1.4.2
Linux 2.4.20 RH9

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to