新手请教,关于JBuilder开发Struts 检查你的struts-config,要是验证的话,要在action的标签里面加上input=xxxx.jsp才行。 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <action name="SMTellWkgListForm" type="com.unihub.svrtool.busman.action.SMTellWkgListAction" input="/busman/SMTellWkgList.jsp"//这里 path="/busman/SMTellWkgListAction"> <forward name="success" path="/busman/SMTellWkgList.jsp" redirect="false"/></action> 非常感谢,页面没有了错误,但是显示不正确。这是我在 ActionForm中的一段判断: if ((id == null) || (id.length() < 1)) errors.add("id",new ActionError("id.error.idrequired")); if ((age == null) || (age.length() < 1)) errors.add("age",new ActionError("age.error.agerequired"));就是判断为空时加入错误信息。下面是我在 ApplicationResources 中的错误信息:id.error.idrequired=<h3><font color="red">id error</font></h3>age.error.agerequired=<h3><font color="red">age error</font></h3>结果显示出的错误信息是: null null。不知道是什么道理,谢谢。 检查你的web.xml是否有: <init-param> <param-name>application</param-name> <param-value>yourApplicationResources</param-value> </init-param> 第一个struts2小程序就出现404错误? struts2提交路劲 加不加action 我想在页面初始化的时候,从数据库中取出一些值然后放在页面的什么地方,以供javascript调用,应该怎么弄 菜鸟想学JSF 请高手指教 在JAVASCRIPT中取余数用什么函数? 如何用柱状图显示投票结果 有关图片的切换 很容易得的50 分,请问word里怎么敲max、lim...... 请问怎样用JSP实现抽奖程序? 本人想学jsp,麻烦大家推荐几个好的学习网站和免费空间网站. 游标超出最大数 急!急!急! 拯救生命!!Weblogic7如何用Beans??
type="com.unihub.svrtool.busman.action.SMTellWkgListAction"
input="/busman/SMTellWkgList.jsp"//这里
path="/busman/SMTellWkgListAction">
<forward name="success"
path="/busman/SMTellWkgList.jsp"
redirect="false"/>
</action>
这是我在 ActionForm中的一段判断:
if ((id == null) || (id.length() < 1))
errors.add("id",new ActionError("id.error.idrequired"));
if ((age == null) || (age.length() < 1))
errors.add("age",new ActionError("age.error.agerequired"));
就是判断为空时加入错误信息。
下面是我在 ApplicationResources 中的错误信息:
id.error.idrequired=<h3><font color="red">id error</font></h3>
age.error.agerequired=<h3><font color="red">age error</font></h3>结果显示出的错误信息是: null null。不知道是什么道理,谢谢。
<init-param>
<param-name>application</param-name>
<param-value>yourApplicationResources</param-value>
</init-param>