Illep
Illep

Reputation: 16841

Spring adding Tags build error

I have got the following errors and i am unable to find an answer. Can someone help me here.

Description Resource Path Location Type Can not find the tag library descriptor for "http://www.springframework.org/tags" contact.jsp /Spring3HibernateMaven/src/main/webapp/WEB-INF/jsp line 1 JSP Problem

Description Resource Path Location Type Can not find the tag library descriptor for "http://www.springframework.org/tags/form" contact.jsp /Spring3HibernateMaven/src/main/webapp/WEB-INF/jsp line 2 JSP Problem

My JSP code is as follows;

<%@ taglib uri="http://www.springframework.org/tags" prefix="spring" %>
<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form" %>

In my Web.xml the code is as follows;

 <jsp-config>
    <taglib>
        <taglib-uri>http://www.springframework.org/tags/form</taglib-uri>
        <taglib-location>spring-form.tld</taglib-location>
    </taglib>
</jsp-config>

How do i solve this error ?

Upvotes: 1

Views: 16358

Answers (2)

bnguyen82
bnguyen82

Reputation: 6248

I have the same problem although I have already spring-webmvc-3.1.0.RELEASE.jar on Maven repos. When I download jar org.springframework.web.servlet-3.1.0.RELEASE.jar and include in lib. It works.

I don't know why because two jars were totally the same, they just have different names.

Upvotes: 1

GriffeyDog
GriffeyDog

Reputation: 8376

You shouldn't need to configure the taglib in web.xml. Just make sure the org.springframework.web.servlet-xxx.jar is on your classpath (web-inf/lib). It contains the TLD files.

Upvotes: 2

Related Questions