• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Implicit mapping of TLDs

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Im trying to use a custom library that is in a JAR file. The JSP container is suppose to check the TLD files in all JAR files in /WEB-INF/lib and create implicit mapping between the contents of <uri> tags of the TLDs to the location of the JAR files.
This is what I have done so far:
1. Created a taglib.tld in a directory META-INF in the JAR file
2. Specified a URI in the <uri> tag of taglib.tld
3. Placed the JAR file under /WEB-INF/lib
4. Tried to access library with a taglib directive that I specified in the taglib.tld
However, when I use an absolute uri in taglib.tld and try to access the jsp that uses the library I get:
org.apache.jasper.JasperException: This absolute uri (http://www.test.com) cannot be resolved in either web.xml or the jar files deployed with this application
When i use a root relative or non-root relative uri in the <uri> tag of taglib.tld (MyTag or /Mytag) I get:
org.apache.jasper.JasperException: File "/MyTag" not found
Am I missing something ? I've been trying to find the problem for 2 days. Im using Tomcat 4.0.3
Thanks,
Andreas
 
sharp shooter, and author
Posts: 1913
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There's a bug in Tomcat 4.0.3 that actually prevents this from working. Give 4.0.4 a try.
Simon
 
Author
Posts: 160
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Andreas Christoforides:
Am I missing something ? I've been trying to find the problem for 2 days. Im using Tomcat 4.0.3


You can also create a directory 'temp' under your Tomcat distribution's directory (that is, coordinate with 'work', 'conf', 'webapps', and the rest). The Tomcat 4.0.4 distribution works out of the box, as Simon says, because it includes this 'temp' directory by default.
 
Would anybody like some fudge? I made it an hour ago. And it goes well with a tiny ad ...
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic