Last active
December 30, 2017 16:14
-
-
Save lamngockhuong/5f33a6bb732e3f86ccd1e3be24da0198 to your computer and use it in GitHub Desktop.
[Struts 1: Show messages and errors in jsp] #java #struts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html:messages property="NameMessages"/> | |
or | |
<logic:messagesPresent message="true"> | |
<html:messages id="aMsg" message="true"> | |
<logic:present name="aMsg"> | |
<!-- Messages --> | |
<div class="action-message info"> | |
<p class="text"><bean:write name="aMsg" filter="false" /></p> | |
</div> | |
</logic:present> | |
</html:messages> | |
</logic:messagesPresent> | |
================ | |
<html:errors property="NameError"/> | |
or | |
<logic:messagesPresent message="false"> | |
<html:messages id="aMsg" message="false"> | |
<logic:present name="aMsg"> | |
<!-- Warnings--> | |
<div class="action-message failure"> | |
<p class="text"><bean:write name="aMsg" filter="false" /></p> | |
</div> | |
</logic:present> | |
</html:messages> | |
</logic:messagesPresent> | |
----------- | |
Lâm Ngọc Khương | |
http://ngockhuong.com | |
http://codekhongkho.com |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment