tags:

views:

61

answers:

1

I am integrating the displaytag library into my Spring MVC Application. I am using Ant for builds in my project. I have followed the installation directions from the website, which you can find here
Installation Instructions for Displaytag

It states that the dependencies for displaytag use are the following

 commons-logging
 commons-lang
 commons-collections
 commons-beanutils
 log4j

I have downloaded and dropped all of these jars to the WEB-INF/lib directory. I have also selected the Build Path -> Configure Build Path -> Add Jar option in Eclipse to configure the build path. I am still receiving an error in my JSP telling me

Can not find tag library descriptor for http://displaytag.sf.net

and it is underlining the URI in the following tag lib directive

 <%@ taglib uri="http://displaytag.sf.net" prefix="display"%>

I am aware of the many posts with this error, and that it typically has to do with dropping the correct Jars in the lib directory or specifying an incorrect URI, but I have copied and pasted the above code from the website. Does anybody know anything else that I need to check/configure?

+2  A: 

I assume that you put the displaytag.jar file in WEB-INF/lib and on your build path as well ...

The message is telling you that it cannot find the TLD file for the tag library. Eclipse should be able to find the TLD file in the META-INF directory of displaytag.jar with a file suffix of .tld.

I guess another possibility is that the .tld isn't in the JAR file.

EDIT

what is wierd is I was using the displaytag 1.2, and I recieved this error, but I just downloaded 1.1 and it is working fine...any suggestions?

No idea. There are ".tld" files in the expected place in both displaytag 1.1 and 1.2, based on the copies I downloaded.

I guess it is possible that you had a bad download, or that the displaytag 1.2 TLD is broken in some non-obvious way. Or maybe it is just some random Eclipse bug ...

Stephen C
I have put the displaytag.jar in the WEB-INF/lib directory and on the build path
CitadelCSAlum
i didnt mean to, it was an accident and when I went back to change it, it told me I couldnt up vote it unless u edited it, if you edit it, I can change it.
CitadelCSAlum
what is wierd is I was using the displaytag 1.2, and I recieved this error, but I just downloaded 1.1 and it is working fine...any suggestions?
CitadelCSAlum
@CitadelCSAlum: You can revoke your negative vote by clicking negative again. Then you can cast an upvote too.
Adeel Ansari
I figured something else out. When you go to sourceforge.net to download the files, if you click on the main download it downloads "display.jar", this is what I initially had dropped in my WEB-INF/lib and it was not recognizign it. After display-1.1.jar worked, I went back and expanded the files and downloaded display-1.2.jar and dropped it and it worked perfectly fine. Anyway, thank you for your help.
CitadelCSAlum