idea中SpringBoot与jsp整合,404页面找不到

报如下错误:

Whitelabel Error Page

This application has no explicit mapping for /error, so you are seeing this as a fallback.

Sun Oct 04 21:23:05 CST 2020
There was an unexpected error (type=Not Found, status=404).
/WEB-INF/jsp/user/details.jsp
idea中SpringBoot与jsp整合,404页面找不到

首先在网上找到如下解决方案:

在working directory中写上自己模块或者项目的路径
idea中SpringBoot与jsp整合,404页面找不到

但是添加之后还是报错

经过长久时间的探索之后发现是webapp名字写错了,因为idea添加框架支持里面的
1、点击右键,选择Add Framework Support
idea中SpringBoot与jsp整合,404页面找不到
2、选择Web Application之后出来是web而不是webapp目录,所以还是报这个错。
idea中SpringBoot与jsp整合,404页面找不到

改成webapp名字之后,项目就可以正常启动了

idea中SpringBoot与jsp整合,404页面找不到

当然项目结构里面的路径也要改对

idea中SpringBoot与jsp整合,404页面找不到

正常启动截图

idea中SpringBoot与jsp整合,404页面找不到