.jsp:
<html:messages id="msg" header="msg.header" footer="msg.footer" message="true">
<bean:write name="msg"/>
</html:messages>
.properties:
msg.header=错误:
msg.footer=
Action类的execute方法:
ActionMessages msgs = new ActionMessages();
msgs.add( ActionMessages.GLOBAL_MESSAGE ,
new ActionMessage( "login.failed" ) );
saveMessages( request , msgs );
这个一般用于显示出错消息,没错的时候(包括可能的表单验证出错)不显示。
<html:messages id="msg" header="msg.header" footer="msg.footer" message="true">
<bean:write name="msg"/>
</html:messages>
.properties:
msg.header=错误:
msg.footer=
Action类的execute方法:
ActionMessages msgs = new ActionMessages();
msgs.add( ActionMessages.GLOBAL_MESSAGE ,
new ActionMessage( "login.failed" ) );
saveMessages( request , msgs );
这个一般用于显示出错消息,没错的时候(包括可能的表单验证出错)不显示。
解决方案 »
- java远程连接linux服务器并读取文件大小
- 求各位站长围观
- 问个window.open取值的问题
- 小弟刚学java,问个初级问题:URL与URI的区别。请高手不吝指点!
- 一个关于叶面连接的问题 急!(在线等待)
- 关于bean的问题
- Tomcat,Oracle,jdbc的问题!!!
- jakarta-tomcat-4.0-b1 的配置问题
- 请教:如何将Tomcat服务器端的输出信息输入到一log文件中
- mssql 2000 中无法添加数据!但是能够读取数据?
- tomcat下使用内存超过100M报错,可以解决吗?
- 菜鸟求助!如何写public interface ResultSetMetaData这个接口的getColumnCount 方法?谢谢大哥大姐了!毕设冲刺中 急急!!!!!!!1
struts1.2之后使用的都是<html:messages>
而之前都是使用的<htnl:errors>
<html:errors/>
接分
祝贺大家节日快乐