Discussions

Web tier: servlets, JSP, Web frameworks: Newbie - Error when compiling JSP that uses a Tag Library

  1. Hello,

    I'm experiencing a problem when compiling my jsp usin forte. My Jsp file references the following tag library as shown below:

    <%@taglib prefix="artist" uri="WEB-INF/artistTags.tld" %>


    I get the following error message when i compile the jsp file:

    web/JSP/music_home.jsp [2:0] Unable to open taglibrary WEB-INF/artistTags.tld : Could not locate TLD META-INF/taglib.tld

    Any suggestions on how to resolve this problem will be most appreciated.

    Kind Regards,

    Rudi
  2. I believe you may have forgotten a slash preceding WEB-INF

    instead of:

    <%@taglib prefix="artist" uri="WEB-INF/artistTags.tld" %>


    you may have meant:

    <%@taglib prefix="artist" uri="/WEB-INF/artistTags.tld" %>

    It's reporting the META-INF/taglib.tld error because you can store tlds in the jar file in the META-INF. Since your URI was malformed, it must have assumed that the tld was in a jar file.

    Hope this helps
  3. Joseph Thanks, I solved the problem a few minutes after i posted it on this site.

    Thanks again.

    Rudi