SpringBoot默认是不支持JSP解析,需要使用tomcat内置的JSP解析功能,需要引入的相关jar包如下:
<!---引入嵌入式tomcat用于支持网页解析--->
<dependency><groupId>org.springframework.boot</groupId><artifactId>spring-boot-starter-web</artifactId><version>2.3.2.RELEASE</version>
</dependency><!---用于支持JSP--->
<dependency><groupId>javax.servlet</groupId><artifactId>jstl</artifactId><!---只编译,运行和打包均不参与---><scope>provided</scope>
</dependency>
<dependency><groupId>javax.servlet</groupId><artifactId>javax.servlet-api</artifactId><scope>provided</scope>
</dependency>
<dependency><groupId>org.apache.tomcat.embed</groupId>