摘要:
使用JSP大约有下列三种跳转方式:1. response.sendRedirect();2. response.setHeader("Location","");3. <jsp:forward page="" />经过试验得到下面的一些规则:一. response.sendRedirect()此语句前不允许有out.flush(),如果有out.flush(),会有异常:java.lang.IllegalStateException: Can't sendRedirect() after data has committed 阅读全文