Struts 1 - problem in showing ActionMessages through a JSP page
- by Yatendra Goel
I am using Struts 1.3.10. I am trying to display ActionMessage and ActionError set by Action class through a JSP page.
The problem is that the ActionErrors are displaying well but ActionMessages are not displaying. When I debug the application, I found that the messages (reference variable of ActionMessages) contains messages. I also saved those messages through saveMessages(request, messages) method of Action class.
So, I think that the problem is in the JSP code through which I am trying to display those messages. The JSP code is as follows:
<logic:messagesPresent>
<ul id="messsages">
<html:messages id="msg" message="true">
<li><bean:write name="msg"/> </li>
</html:messages>
</ul>
</logic:messagesPresent>