在用springboot对html的页面进行渲染时,页面找不到报404(type=Not Found, status=404).,

解决办法:是在ctroller层加相应的           @RequestMapping("root")

 

@Controller
public class FrasAdminCotrller {
    @RequestMapping("root")
    public String  login(){
         return "admin/root";     (admin中root,为root.html)

    }

 且 

 @RequestMapping("XXX")中的XXX要和XXX.html保持一致!!!!!

相关文章:

  • 2021-10-31
  • 2022-12-23
  • 2021-07-11
  • 2022-12-23
  • 2022-12-23
  • 2021-08-24
猜你喜欢
  • 2021-08-11
  • 2021-12-21
  • 2021-06-20
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-08-08
相关资源
相似解决方案