jsp通过url传递参数
在第一个jsp页面中
<script type="text/javascript">
function chk(id, cla, sts) {
if (confirm("你确定要修改吗?")) {
location.href = "update.jsp?pid=" + id + "&pcla=" + cla + "&psts="+ sts;
}
}
</script>
<td style="overflow:hidden"><input type="button" onclick="chk('<%=roo.getId()%>,<%=roo.getCla()%>,<%=roo.getState()%>')" value="修改" style="width:60;"/></td>
第二个jsp页面
String roomno = request.getParameter("pid");
String cla = request.getParameter("pcla");
String sta = request.getParameter("psts");
点击修改后url为 http://localhost:8080/ResLogin/update.jsp?pid=1,%E8%B1%AA%E5%8D%8E%E5%A5%97%E9%97%B4,l&pcla=undefined&psts=undefined
怎么解决??