• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

.tld files and uri

 
Maan Suraj
Ranch Hand
Posts: 299
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have 3 .tld files within the same application. The name of these files are:
simple.tld,
simple2.tld,
simple3.tld

uri for all .tld files is "simpleTags"

There are three JSPs which call a respective .tld file.

I want to know is it necessary to keep different URIs for the above three .tld files.

As i mentioned above, i had the same uri for all the three .tld files(i.e uri simpleTags).

simple and simple2.tld worked, however simple3.tld threw an error as mentioned below


org.apache.jasper.JasperException: /useTag_al.jsp(5,0) No tag "simple3" defined in tag library imported with prefix "myTags"
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:40)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:198)
org.apache.jasper.compiler.Parser.parseCustomTag(Parser.java:1220)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1456)
org.apache.jasper.compiler.Parser.parse(Parser.java:133)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:216)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:103)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:153)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:314)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:294)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:281)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:337)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)


note The full stack trace of the root cause is available in the Apache Tomcat/6.0.16 logs.


--------------------------------------------------------------------------------

Apache Tomcat/6.0.16




I changed the uri for simple3.tld and in the calling jsp and ithe error was resolvedWhy is it so....and if it's mandatory to keep different uri for each .tld file, then howcome simple2.tld worked fine?

[ November 02, 2008: Message edited by: Maan Shenoy ]
 
Maan Suraj
Ranch Hand
Posts: 299
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
no response yet from anyone.....please tell me if my question is not clear enough......
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There must be one unique uri for each library. The container will not add duplicate entries when it maps uris to tlds.

then howcome simple2.tld worked fine

I don't know, and don't even want to think about it Don't duplicate uris.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic