2 Replies Latest reply on May 7, 2003 3:22 PM by 843835

    error in tablib by the time of running jsp


      I am getting the following error when i try to run the jsp using tablibs ...

      Error: 500
      Location: /test/test.jsp
      Internal Servlet Error:

      org.apache.jasper.compiler.CompileException: /usr/tomcat/webapps/test/test.jsp(0,0) Unable to open taglibrary : Parse Error in the tag library descriptor: Illegal character at end of document, <.
           at org.apache.jasper.compiler.JspParseEventListener.handleDirective(JspParseEventListener.java:713)
           at org.apache.jasper.compiler.DelegatingListener.handleDirective(DelegatingListener.java:116)

      Here is my code:
      new-tag file:-

      import javax.servlet.jsp.*;
      import javax.servlet.jsp.tagext.*;

      public class new_tag extends javax.servlet.jsp.tagext.TagSupport
      private String message = "message not available";

      public int doStartTag() throws JspException
      catch (Exception e)
      throw new JspTagException(e.getMessage());
      return SKIP_BODY;

      public void setMessage(String text)
      message = text;
      web.xml: -

      <taglib-uri> </taglib-uri>
      example-taglib.tld :--

      <?xml version="1.0" encoding="UTF-8" ?>

      <!DOCTYPE taglib PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN"

      <description>Info about the new tag</description>

      <%@ taglib uri="" prefix="ctl" %>
      <ctl:new_tag message="Creating a new function with JSP"></ctl:new_tag>

      Any help please ...