【发布时间】:2011-06-26 11:51:46
【问题描述】:
我有这个 servlet:
public class SaveImage extends HttpServlet {
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
PrintWriter out = null;
try {
out = response.getWriter();
out.println("<html>");
...
// I want to include here the content of this jsp:
// /WEB-INF/mybox.jsp
// (also, with the full context of the servlet)
...
out.println("</html>");
out.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}
这样做有问题吗(响应已经提交?),我该怎么做?
【问题讨论】: