Referer: public void referer(HttpServletRequest request, HttpServletResponse response) throws Exception { String referer = request.getHeader("referer"); if (referer == null || !referer.startsWith("http://localhost")) { response.sendRedirect("/webTwo/index.jsp"); return; } String data = "welcome"; response.getOutputStream().write(data.getBytes()); } 编写URL技巧: 先写'/',...
[ 查看全文 ]