`
xiongzhenhui
  • 浏览: 206056 次
  • 性别: Icon_minigender_1
  • 来自: 厦门
社区版块
存档分类
最新评论

webwork.devMode设置为true会报ognl异常原因

阅读更多

 

No object in the CompoundRoot has a publicly accessible property named 'index2'

在设置webwork的devMode为true后,启动时出现下列异常:

引用
com.opensymphony.xwork.interceptor.ParametersInterceptor - Developer Notification (set webwork.devMode to false to disable this message):
No object in the CompoundRoot has a publicly accessible property named 'Submit' (no setter could be found)


原因就是devMode下form中的input会在action中找针对input name 的setter(webwork.devMode = false 译注:设置为true时,所有有名字(name)的input都必须有对应的setter),页面jsp中name为Submit的标签在action中没有对应的setter方法所致;解决办法就是注掉devMode true:
Xml代码 复制代码 收藏代码
  1. #webwork.devMode=true  
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics