html静态文件放在static下,用@Controller注解,以下第一种方式成功,第二种方式失败。一、@Controller@RequestMapping("/")public class IndexController {public ModelAndView index() {return new ModelAndView("index");}}二、@Controllerpublic class IndexController {@RequestMapping("/")public ModelAndView index() {return new ModelAndView("index");}}