The browser accesses the sp page and the file download occurs

Springboot builds a Java Web project, which returns the response of requesting the jsp page in the control layer, but browsing on the browser just displays and downloads a file containing the content of the jsp page. Later, it was found that the dependencies that support jsp were not imported. After importing the jsp dependencies, the page information was successfully displayed.

depends on

 <dependency>
                <groupId>javax.servlet.jsp</groupId>
                <artifactId>jsp-api</artifactId>
                <version>2.2.1-b03</version>
                <scope>provided</scope>
  </dependency>

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325573684&siteId=291194637