需求:
也就是servlet的转发和重定向在spring中的使用
实现:
基于RedirectView 或者直接基于定位符
@RequestMapping(value = "/save", method = RequestMethod.POST)
public String save(HttpServletRequest request, HotWord hotWord) {
String url = "redirect:/hotword/list";
return url;
}
其中有forward和redirect,具体区别等同于servlet