主题 : jquery为什么只能返回true和false呢
级别: 童生
UID: 13683
积分:10 加为好友
威望: 0 精华: 0
主题:0 回复:10
注册时间:2010-12-20
在线时长:0
1#   发表于:2011-01-29 14:01:23  IP:125.108.*.*
我在前台了
var linksdiv=$("#linkcont");
$.post("${base}/jeecms/core/ajax/links/checkLinks.do",{links:lin},function(data){
alert(data);
},"json");
后台写
public String checkLinks(){
try {
HttpServletResponse response = ServletActionContext.getResponse();
response.setContentType("text/html;charset=UTF-8");
PrintWriter out=response.getWriter();
out.print("abcdef");
out.flush();
} catch (IOException e) {
System.out.println("输出时异常");
}
return null;
}
红色的地方,如果是true或false的话,在前台可以显示
,但是其它的东西就不行了。。请问这是为什么呢
1 共1页