Reputation: 111
I have below code. How to handle in struts2 of logic:messagesPresent
which is for checking the property and display the <tld:label id="changepwd.error.info1" /
> which is my jsp tag library and I think it can remain in struts2 as I have tested it can show the text.
<logic:messagesPresent property="error.message.missingNewPassword">
<tld:label id="changepwd.error.info1" />
</logic:messagesPresent>
Upvotes: 0
Views: 1220
Reputation: 5122
logic:messagesPresent
can be used only Struts 1.x.
You can use hasActionMessages()
or hasActionErrors()
instead of it, for example:
<s:if test="hasActionMessages()">
<tld:label id="changepwd.error.info1" />
</s:if>
Upvotes: 2