Alpay Ozturk wrote:
Hi All,

I am having a problem with ActionMessages. When I create an
ActionMessages instance in my action and add ActionMessage objects to
it, it is not displayed in my result jsp. But when I create an
ActionErrors instance and add ActionMessage ojects to it, it is
displayed. Below are the action and jsp codes. Only entry with key
error.2 is displayed in result jsp. What am I missing here?

//Action Class
ActionMessages actionMessages = new ActionMessages();
actionMessages.add("test", new ActionMessage("error.1"));
saveMessages(request, actionMessages);
ActionErrors actionErros = new ActionErrors();
actionErros.add("test2", new ActionMessage("error.2"));
saveErrors(request, actionErros);
return mapping.findForward("success");


//result jsp
   <html:messages id="actionMessage" property="test">
      <li><bean:write name="actionMessage"/></li>
   </html:messages>

   <html:messages id="actionError" property="test2">
      <li><bean:write name="actionError"/></li>
   </html:messages>



Alpay -

Try
<html:messages id="message" property="test">
and
<html:messages id="error" property="test2">

instead of saying actionMessage/actionError.

Matt

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



Reply via email to