问一下在struts2中获取ext,或者dojo 的数据出现了异常?这是怎么回事情?

问一下在struts2中获取ext,或者dojo 的数据出现了异常?这是怎么回事情?
我的客户端:

function login() {
dojo.xhrGet({
url: "login.htm",
handleAs: "json",
load: function(data){
// dojo.byId('myBox').value = data;
console.debug("success: ", data);
},
error: function(data){
console.debug("An error occurred: ", data);
},
form: "loginFrom"
});
}
dojo.connect(dojo.byId("sub"),"onclick",login);



在 struts2的action中代码:

HttpServletRequest requests=ServletActionContext.getRequest();
System.out.println("UserName :: "+requests.getParameter("UserName"));



出现了这个错误:

2008-11-04 10:52:41,671 [com.opensymphony.xwork2.interceptor.ParametersInterceptor]-[ERROR] ParametersInterceptor - [setParameters]: Unexpected Exception caught setting 'Password' on 'class com.fantong.canting.web.action.LoginAction: Error setting expression 'Password' with value ['test', ]
2008-11-04 10:52:41,671 [com.opensymphony.xwork2.interceptor.ParametersInterceptor]-[ERROR] ParametersInterceptor - [setParameters]: Unexpected Exception caught setting 'UserName' on 'class com.fantong.canting.web.action.LoginAction: Error setting expression 'UserName' with value ['test', ]




在提交的数据中没有问题呀;怎么回出现这个问题,如何解决???
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章