POST 重定向

    @RequestMapping("/mapping")
public RedirectView edit(HttpServletRequest request, ModelMap model) throws Exception {
for (Map.Entry<String, String[]> entry : request.getParameterMap().entrySet()) {
model.put(entry.getKey(), entry.getValue());
}
RedirectView redirectView = new RedirectView();
redirectView.setUrl("http://www.XXXX.com/a/b/c");
redirectView.setStatusCode(HttpStatus.TEMPORARY_REDIRECT);
// redirectView.setHttp10Compatible(Boolean.TRUE);
return redirectView;
}
展开阅读全文

没有更多推荐了,返回首页