Can not find the tag library descriptor of springframework

后端 未结 14 1934
一向
一向 2020-11-30 07:10

I\'m trying to follow the example of spring JPetStore but I get an error in the JSP pages in the line that references the lib tag spring:

Can not find the ta

相关标签:
14条回答
  • 2020-11-30 08:14

    you have to add the dependency for springs mvc

    tray adding that in your pom

    <!-- mvc -->
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-webmvc</artifactId>
        <version>3.1.2.RELEASE</version>
    </dependency>
    
    0 讨论(0)
  • 2020-11-30 08:16
    1. Download the Spring dependency jar
    2. Place it to the lib folder path is /WEB-INF/lib/spring.jar
    3. Then open the web.xml and the sample code is:

      <taglib>
        <taglib-uri>/WEB-INF/spring.tld</taglib-uri>
        <taglib-location>/WEB-INF/spring.tld</taglib-location>
      </taglib>
      
    4. Then the taglib is indicated where the jar file locates in ur system.

      <%@ taglib prefix="spring" uri="/WEB-INF/spring.tld" %>
      
    0 讨论(0)
提交回复
热议问题