Taglib problem in JSP

I'm using JFreeChart to display the chart and I define the following taglib in my JSP.
<%@ taglib uri="/WEB-INF/chartlib.tld" prefix="chartlib" %>
It works in Tomcat and WebLogic, but not webtogo, got this exception.
java.lang.NoClassDefFoundError: Illegal name: /WEB-INF/chartlib.tld
     at java.lang.ClassLoader.defineClass(Unknown Source)
     at java.lang.ClassLoader.defineClass(Unknown Source)
     at oracle.lite.web.ServletHandler$ServletClassLoader.loadClass(Unknown Source)
     at java.lang.ClassLoader.loadClass(Unknown Source)
     at oracle.jsp.parse.JspUtils.loadClassJDK(JspUtils.java:219)
     at oracle.jsp.parse.JspUtils.loadClass(JspUtils.java:209)
I have to hardcode the app name in order to make it work. Is there any good solution?
<%@ taglib uri="//webapp/WEB-INF/chartlib.tld" prefix="chartlib" %>
And it just solve the exception problem, it actually cannot show the chart. Anyone use the jfreechart or has problem in using custom tag library?
Matthew

I put the chartlib.tld in /WEB-INF/ and here is my web.xml. The uri of the taglib directive in JSP is exactly the taglib-uri here for each case.
<taglib>
<taglib-uri>/WEB-INF/chartlib.tld</taglib-uri>
<taglib-location>/WEB-INF/chartlib.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>chartlib-01.tld</taglib-uri>
<taglib-location>/chartlib.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>chartlib-02.tld</taglib-uri>
<taglib-location>/no_chartlib.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>chartlib-03.tld</taglib-uri>
<taglib-location>/WEB-INF/chartlib.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>chartlib-04.tld</taglib-uri>
<taglib-location>chartlib.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>chartlib-05.tld</taglib-uri>
<taglib-location>no_chartlib.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB/chartlib.tld</taglib-uri>
<taglib-location>/WEB-INF/chartlib.tld</taglib-location>
</taglib>
And I have modified the source code in JspDirectiveTaglib.java to output some debug message, where s1 is the value of uri in JSP, s3 is the value of taglib-location in web.xml. Here is the result. It tries to load s1 first. If it returns null, then it reads the tld file s2. It shows that the leading '/' represent the webapp dir. If it is relative (i.e. no '/'), it refers to the /WEB-INF as you can see the program automatically add it in the beginning. Finally, the message "loader MyChartTag" shows that it loads my tag class successfully.
----Case 1: this should be the normal/ideal case, but in fact it fails.
----It loads the tld file but it is not a class, so throws the error.
JspDirectiveTaglib:uri(s1)=[WEB-INF/chartlib.tld]
JspDirectiveTaglib:s3=[WEB-INF/chartlib.tld]
JspDirectiveTaglib:loadClass(s1)=[WEB-INF/chartlib.tld]
log1: loader: /WEB-INF/chartlib.tld
log9: JspServlet: unable to dispatch to requested page: java.lang.NoClassDefFoundError:
Illegal name: /WEB-INF/chartlib.tld
----Case 2: try to read tld in root dir.
JspDirectiveTaglib:uri(s1)=[chartlib-01.tld]
JspDirectiveTaglib:s3=[chartlib.tld]
JspDirectiveTaglib:loadClass(s1)=[chartlib-01.tld]
JspDirectiveTaglib:class1=null
log9: JspServlet: unable to dispatch to requested page: oracle.jsp.parse.JspParseException:
Error: java.io.FileNotFoundException:
F:\webapp\chartlib.tld (???????????)
----Case 3: try to read a non-existing tld to see where is the root dir.
JspDirectiveTaglib:uri(s1)=[chartlib-02.tld]
JspDirectiveTaglib:s3=[no_chartlib.tld]
JspDirectiveTaglib:loadClass(s1)=[chartlib-02.tld]
JspDirectiveTaglib:class1=null
log9: JspServlet: unable to dispatch to requested page: oracle.jsp.parse.JspParseException:
Error: java.io.FileNotFoundException:
F:\webapp\no_chartlib.tld (???????????)
----Case 4: try to read tld in absolute dir.
JspDirectiveTaglib:uri(s1)=[chartlib-03.tld]
JspDirectiveTaglib:s3=[WEB-INF/chartlib.tld]
JspDirectiveTaglib:loadClass(s1)=[chartlib-03.tld]
JspDirectiveTaglib:class1=null
log1: loader: MyChartTag
----Case 5: try to read tld in relative dir, but the path is changed by the program.
JspDirectiveTaglib:uri(s1)=[chartlib-04.tld]
JspDirectiveTaglib:s3=[WEB-INF/chartlib.tld]
JspDirectiveTaglib:loadClass(s1)=[chartlib-04.tld]
JspDirectiveTaglib:class1=null
log1: loader: MyChartTag
----Case 6: try to read a non-existing tld in relative dir, but the path is changed by the program.
JspDirectiveTaglib:uri(s1)=[chartlib-05.tld]
JspDirectiveTaglib:s3=[WEB-INF/no_chartlib.tld]
JspDirectiveTaglib:loadClass(s1)=[chartlib-05.tld]
JspDirectiveTaglib:class1=null
log9: JspServlet: unable to dispatch to requested page: oracle.jsp.parse.JspParseException:
Error: java.io.FileNotFoundException:
F:\webapp\WEB-INF\no_chartlib.tld (???????????)
----Case 7: try to compare to case 1 if the uri specifies an invalid path.
JspDirectiveTaglib:uri(s1)=[WEB/chartlib.tld]
JspDirectiveTaglib:s3=[WEB-INF/chartlib.tld]
JspDirectiveTaglib:loadClass(s1)=[WEB/chartlib.tld]
JspDirectiveTaglib:class1=null
log1: loader: MyChartTag

Similar Messages

  • Initial problem with JSP Custom Tag devolopment

    Hi ,
    I have encountered a problem with my JSP application which utilizes a simple custom tag.
    First I created followinng directories.
    1. %TOMCAT_HOME%\webapps\testTags
    2. %TOMCAT_HOME%\webapps\testTags\META-INF
    3. %TOMCAT_HOME%\webapps\testTags\WEB-INF
    4. %TOMCAT_HOME%\webapps\testTags\WEB-INF\tlds
    5. %TOMCAT_HOME%\webapps\testTags\WEB-INF\classes
    6. %TOMCAT_HOME%\webapps\testTags\WEB-INF\classes\com
    7. %TOMCAT_HOME%\webapps\testTags\WEB-INF\classes\com\tek271
    8. %TOMCAT_HOME%\webapps\testTags\WEB-INF\classes\com\tek271\testTags
    I created the essential four files, that is named as follows.
    1.TagError.java
    2.web.xml
    3.testTld.tld
    4.testJsp.jsp
    Then i put the files under these directories as given below
    testJsp.jsp under %TOMCAT_HOME%\webapps\testTags.
    web.xml under %TOMCAT_HOME%\webapps\testTags\WEB-INF
    TagError.java under %TOMCAT_HOME%\webapps\testTags\WEB-INF\classes
    TagError.class under %TOMCAT_HOME%\webapps\testTags\WEB-INF\classes\com\tek271\testTags
    testTld.tld %TOMCAT_HOME%\webapps\testTags\WEB-INF\tlds
    Here is the content inside the files.
    1.TagError.java
    package com.tek271.testTags;
    import java.io.*;
    import javax.servlet.jsp.*;
    import javax.servlet.jsp.tagext.*;
    public class TagError extends TagSupport {
    private String mColor = "red";
    public void setColor(String aColor) {
    mColor = aColor;
    } // setColor
    public int doStartTag() throws JspException {
    try {
    JspWriter out = pageContext.getOut();
    out.print("<font color=\"");
    out.print(mColor);
    out.print("\"><b>Error: ");
    } catch (IOException ex) {
    throw new JspTagException(ex.getMessage());
    return EVAL_BODY_INCLUDE; // other return: SKIP_BODY
    } // doStartTag()
    public int doEndTag() throws JspException {
    try {
    JspWriter out = pageContext.getOut();
    out.println("</b></font><br>");
    } catch (IOException ex) {
    throw new JspTagException(ex.getMessage());
    return EVAL_PAGE; // other return: SKIP_PAGE
    } // doEndTag()
    } // TagError
    2.web.xml
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <web-app>
    <taglib>
    <taglib-uri>/testTaglib</taglib-uri>
    <taglib-location>/WEB-INF/tlds/testTld.tld</taglib-location>
    </taglib>
    </web-app>
    3.testTld.tld
    <?xml version="1.0" encoding="ISO-8859-1" ?>
    <!DOCTYPE taglib
    PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.1//EN"
    "http://java.sun.com/j2ee/dtds/web-jsptaglibrary_1_1.dtd">
    <taglib>
    <tlibversion>1.0</tlibversion>
    <jspversion>1.1</jspversion>
    <shortname>testTld</shortname>
    <info>Testing jsp tags</info>
    <tag>
    <name>tagError</name>
    <tagclass>com.tek271.testTags.TagError</tagclass>
    <bodycontent>JSP</bodycontent> <!-- Also: empty, tagdependent -->
    <info>Show a string as an error message</info>
    <attribute>
    <name>color</name>
    <required>false</required>
    </attribute>
    </tag>
    </taglib>
    4.testJsp.jsp
    <%@ taglib uri="/testTaglib" prefix="test" %>
    <html>
    <head>
    <title>Testing Tag Library</title>
    </head>
    <body>
    <test:tagError>Invalid user name</test:tagError>
    <test:tagError color="blue">Invalid Password</test:tagError>
    </body>
    </html>
    but i am getting the following error.
    Apache Tomcat/4.0.3 - HTTP Status 500 - Internal Server Error
    type Exception report
    message Internal Server Error
    description The server encountered an internal error (Internal Server Error) that prevented it from fulfilling this request.
    exception
    org.apache.jasper.JasperException: File "/testTaglib" not found
    at org.apache.jasper.compiler.TagLibraryInfoImpl.(TagLibraryInfoImpl.java:214)
    at org.apache.jasper.compiler.TagLibraryInfoImpl.(TagLibraryInfoImpl.java:174)
    at org.apache.jasper.compiler.JspParseEventListener.processTaglibDirective(JspParseEventListener.java:1162)
    at org.apache.jasper.compiler.JspParseEventListener.handleDirective(JspParseEventListener.java:758)
    at org.apache.jasper.compiler.DelegatingListener.handleDirective(DelegatingListener.java:121)
    at org.apache.jasper.compiler.Parser$Directive.accept(Parser.java:255)
    at org.apache.jasper.compiler.Parser.parse(Parser.java:1145)
    at org.apache.jasper.compiler.Parser.parse(Parser.java:1103)
    at org.apache.jasper.compiler.Parser.parse(Parser.java:1099)
    at org.apache.jasper.compiler.ParserController.parse(ParserController.java:213)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:210)
    at org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:552)
    at org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(JspServlet.java:177)
    at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:189)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:382)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:474)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
    at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:190)
    at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
    at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:246)
    at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
    at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2343)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
    at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
    at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
    at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170)
    at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
    at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:468)
    at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
    at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
    at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
    at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
    at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:1012)
    at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1107)
    at java.lang.Thread.run(Thread.java:536)
    why is it like this ?please give me a solution.
    Thanking in advance.
    From
    Vinod A.

    Dear patreck ,
    It does not work.
    I have replaced the line
    <%@ taglib uri="/testTaglib" prefix="test" %>
    with
    <%@ taglib uri="WEB-INF/tlds/testTaglib" prefix="test" %>
    but now it shows the error ,
    description The server encountered an internal error (Internal Server Error) that prevented it from fulfilling this request.
    exception
    org.apache.jasper.JasperException: File "/testTags/WEB-INF/tlds/testTaglib" not found
    any more suggestion ?
    From Vinod A.

  • Taglib - i18n in jsp 2.4

    Hi,
    while migrating the code from websphere 5.1 to websphere 6.1,
    am facing taglib problem.
    in index.jsp, i have added
    <%@ taglib uri="http://jakarta.apache.org/taglibs/i18n-1.0" prefix="i18n"%>
    this cause error as
    JSPG0047E: Unable to locate tag library for uri http://jakarta.apache.org/taglibs/i18n-1.0
    Error code:500
    even i tried with
    <%@ taglib uri="http://jakarta.apache.org/taglibs/i18n" prefix="i18n" %>
    am getting error
    JSPG0047E: Unable to locate tag library for uri http://jakarta.apache.org/taglibs/i18n
    Error code:500
    please help me out...
    what is the latest version of taglib - i18n
    where can i find...
    thanks in advance..
    regards,
    sana .g

    If you need more information, don't know what I mean or whatever, please ask.
    I realy need this but don't know how to do...

  • Problem in jsp with container(JEUS)

    Hi I am a developer in Korea
    Nowadays I have a problem in jsp pages which have contained some pakage directive in a library path
    so my problem is changing some of the classes in the package during service time.
    Error result is
    -Root Exception stack trace :
    -jeus.servlet.jsp.compiler.JspCompileException: fail to compile : source = C:\TmaxSoft\JEUS6.0\webhome\epims_container1\_generated_\j2ee-modules\harweb\jeus_jspwork\_custermg\_html\_mypage\_600_MyReqJob_5fjsp.java, -error msg = C:\TmaxSoft\JEUS6.0\webhome\epims_container1\_generated_\j2ee-modules\harweb\jeus_jspwork\_custermg\_html\_mypage\_600_MyReqJob_5fjsp.java:76: cannot access custermg.MyPageQuery
    bad class file: C:\epims\harweb\WEB-INF\classes\custermg\MyPageQuery.class
    -class file has wrong version 8241.8224, should be 49.0
    -Please remove or make sure it appears in the correct subdirectory of the classpath.
    -     MyPageQuery myquery = null;
    I don't know why this could be happed in random period of time It happens nearly each 10 hours . after this failure, the same error happen in other classes.
    Before ten hours?.... No problem with the jsp pages
    The number 8241.8224 tells me that it is not generated by java compiler but I don't have any clue but the above error
    my run time environment is
    - HP Server, Windows Server 2003, 64bit
    - Jeus, jdk1.5.0_15
    so any help from you will be appreciated...
    thanks

    Mr. Ahmed,
    Excuse-me by my bad english.
    I experienced the same problem when surrounded my scripts with comment caracters:
    <!--
    < SCRIPT ...
    -->
    If this is your case, simply uncomment it and the script will work fine.

  • Problem using jsp:include from inside a custom tag

    Hi, All !
              I have a problem using <jsp:include> from inside a custom tag. Exception is:
              "java.lang.ClassCastException: weblogic.servlet.jsp.BodyContentImpl"
              Apparently, weblogic tries to cast BodyContentImpl to JspWriterImpl and
              could not do this. Is it a bug, since in the 1.1 spec is said: "The
              BodyContent is a subclass of JspWriter that can be used to process body
              evaluations so they can retrieved later on."
              My code is:
              <wfmklist:items>
              <jsp:include page="item.jsp" flush="true"/>
              </wfmklist:items>
              

    This is an area of contention with WL. It is not so tolerant with regards to
              the spec. I spent several days recently trying to convince it to accept the
              specification in regards to bodies and includes and it appears to have
              successfully rebuffed my efforts.
              Frankly, this is very disappointing. It appears that some shortcuts were
              taken on the way to JSP 1.1 support, and the result is a very hard-coded,
              inflexible implementation. As I have not seen the implementation myself, I
              hate to assume this, however one could posit that the term "interface" was a
              foreign concept during the implementation, other than as some annoying
              intermediary reference requiring an immediate cast to a specific Weblogic
              class, which in turn is apparently required to be final or have many final
              methods, as if being optimized for a JDK 1.02 JIT.
              I am sorry that I don't have any positive suggestions other than to use a
              URL object to come back in an execute the necessary "include" directly. You
              lose all context (other than session) and that can cause its own problems.
              However, you can generally get the URL approach to work, and you will
              hopefully avoid further frustration.
              Peace,
              Cameron Purdy
              Tangosol, Inc.
              http://www.tangosol.com
              Tangosol: How Weblogic applications are customized
              "Denis" <[email protected]> wrote in message
              news:[email protected]...
              > Hi, All !
              > I have a problem using <jsp:include> from inside a custom tag. Exception
              is:
              > "java.lang.ClassCastException: weblogic.servlet.jsp.BodyContentImpl"
              >
              > Apparently, weblogic tries to cast BodyContentImpl to JspWriterImpl and
              > could not do this. Is it a bug, since in the 1.1 spec is said: "The
              > BodyContent is a subclass of JspWriter that can be used to process body
              > evaluations so they can retrieved later on."
              >
              > My code is:
              > ...
              > <wfmklist:items>
              > <jsp:include page="item.jsp" flush="true"/>
              > </wfmklist:items>
              > ...
              

  • Urgent Solution needed--Problem in JSP compilation with JDK 1.5 and JDK 1.6

    Hi,
    I m using JDK 1.5 and Tomcat 5.0 the problem is that after starting server when I m going to access my application at that time instead of displaying HomePage it directly display the blank page on screen.
    After analyzing tomcat log I have found that there was a problem with JSP page compilation.
    The exception logged in Tomcat Log is given below
    An error occurred at line: 1 in the generated java file
    The type Collection is not generic; it cannot be parameterized with arguments <? extends E>
    Stacktrace:
    *     at org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:92)*
    *     at org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)*
    *     at org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:423)*
    *     at org.apache.jasper.compiler.Compiler.compile(Compiler.java:308)*
    *     at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)*
    *     at org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)*
    *     at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)*
    *     at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)*
    *     at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)*
    *     at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)*
    *     at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)*
    *     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)*
    *     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)*
    *     at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)*
    *     at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:447)*
    *     at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:379)*
    *     at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:292)*
    *     at org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.java:424)*
    *     at org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:343)*
    *     at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:144)*
    *     at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)*
    *     at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)*
    *     at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:263)*
    *     at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)*
    *     at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:584)*
    *     at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)*
    *     at java.lang.Thread.run(Thread.java:619)*
    After getting this kind of error I have analyzed my code furhter then I came to know that there was problem with static include tag.
    In my jsp page I have used following line which is the main cause of error
    <%@ include file="top.jsp" %>If I ommit this line then it is working properly.
    Instead of static include I have used jsp:include also.
    Still I m getting same problem.
    We have to migrated from JDK 1.5 to 1.6 and Tomcat 5.0.28 to 6.0.14, still same problem is there.
    We have tried a lot but didnt get success to overcome this problem.
    If anybody having any solution then ur each reply will be appreciated.
    Thanks in advance..........!!!!!!!
    Edited by: JBOSS2000 on Jan 15, 2008 9:29 AM

    Hi "mshanu" and "amit" Thanks for ur replies Here I m posting the code of "top.jsp"........!!!!
    <%@ page errorPage="errordisplay.jsp"%>
    <table cellpadding="0"
           cellspacing="0"  height=50 width=780>
           <tbody>
             <tr class="header">
               <td class="logo"><IMG SRC="assets/Logo.gif" BORDER=0 ALIGN=top></td>
               <td align="right"><span class="applicationtitle"><%@ include file="/contents/logo.htm" %></span><br>
               <span class="companyname"><%@ include file="/contents/companyname.htm" %></span></td>
             </tr>
            </tbody>
    </table>To include top.jsp I have tried
    <jsp:include page="top.jsp" flush="true">
    </jsp:include>
             AND       
    <%@ include file="top.jsp"%>but none of this worked.
    If I remove the include then It is working properly.
    But I need inluded file too so that I am wondoring for the solution.
    This problem seems very wiered to me. I dont know why it is happening.
    This problem is started only when I used the TOMCAT 6.14.
    Is it the bug of TOMCAT 6.14 or What somebody Plz help.
    I got stuck here.........!!!!!!!!!!
    It doesn't seem any problem with top.jsp. As per my thinking the problem is there in include due to that it doesn't compile the JSP page in Tomcat 6.0.
    Earlier I am having same code running on the Tomcat 5.0.28 and JDK 1.5.0.
    But problem occured when I have used Tomcat 6.x...!!

  • Language problem in JSP please help

    Hi all java guru;
    Altough I tried all different way I can not solve the my problem.
    My problem is Turkish language problem in JSP.
    If my jsp page use database applications such as push or pull data to my SQL 2000 database or call some datas from database, some data which contains turkish caracter are seen wrong. suc as ����� is to ??????
    what is the problem?
    But important point is that; this is only Database data which come from sql database. But I can see JSP data or HTML data truly.
    I try different method to solve in JSP page;
    1-request.setEncoding("iso-8859-9");
    or
    request.setCharacterEncoding( "windows-1250" );
    2-
    @contentType="text/html; charset=iso-8859-9"
    @page pageEncoding="iso-8859-9"
    3-
    <meta http-equiv="Content-Language" content="tr">
    <META http-equiv="Content-Style-Type" content="text/css">
    4-
    ISO-8859-9 is turkish charecter spefications
    String TR_tlp = new String(NEW_TALEP.getBytes(),"ISO-8859-9"); // this parm is inserting database but problem is go on.
    5-
    for the database...
    Properties props = new Properties();
    props.put("user","login");
    props.put("password","password");
    props.put("charSet","UNICODE");
    6-
    url= "jdbc:microsoft:sqlserver://IP_NO:1433;databasename=database;TRUSTED_CONNECTION = true;CHARSET="+sun.io.ByteToCharConverter.getDefault().getCharacterEncoding();
    or
    url= "jdbc:microsoft:sqlserver://IP_NO:1433;databasename=database;TRUSTED_CONNECTION = true;CHARSET=ISO-8859-9"
    con= DriverManager.getConnection(url, kulad, sifre);
    I am using tomcat 5.0.19,
    is there any way to solve this problem... Please help......

    Were you ever able to solve your problem?
    I have a similar problem.
    My database is storing the characters correctly and they can be viewed in Java, but when I try to convert them to unicode using:
    String inputUtf8 = new String(input.getBytes(),charset);
    it works for almost all characters, but some come through as noncharacter "boxes."
    The characters that come through as boxes in iso8859-1 are the ones that are in the "supplementary" character range of that set, such as:
    - curved left and right quotes
    - "TM" symbol
    - bullets
    - m dash and n dash
    (see this table: http://www.csgnetwork.com/htmlchrset.html for a more complete list of the supplementary characters )
    Any idea what I need to do to have these characters show up properly?

  • Yet more TagLibs problems

    As jato2 still doesn't know about some HTML4 tags like <label>
    ex:
    <label><input type="radio" ... />TheLabel</label>
    if you click on "TheLabel", it clicks on the radio button, like every
    other GUI
    I thought I would be able use the <label for=""> as a workaround
    <input type="radio" name="choice" id="choice1" /> <label
    for="choice1">TheLabel</label>
    BUT despite it generates several tags, <jato:radioButtons> sets the id
    attribute to the same value for every tag :< This not only defeats my
    workaround but also id main purpose to uniquely identity elements.
    We really need a generic mechanism to specify attributes when jato tags
    generate multiple HTML tags.
    I can still change the generated tags in endDisplay but it be neat if
    the 201 taglib was a little bit more XHTML compliant and savvy ;)
    Fr?d?ric
    ps: release this part of the source code and we'll do it !

    Give me until monday and I'll have what you "ask" for (WML/XHTML
    Basic/Mobile as well as ViewBean).
    Following Todd advices,
    for the former, I am having new tags to render the same components. I
    may need to write new components but I'm not sure yet.
    for the latter, 1 pagelet per "rendering" type with an inner
    ContainerView when the logic is different ; the pagelet tags being
    surrounded by a homemade tag that "activates" the pagelet based on the
    client type. A specialized tag seems better than <jato:content> as the
    logic is wired.
    Further step would be to make the tags client aware but I'm not sure
    yet it is the right thing to do. Are tags "allowed" to store data in
    the session (to avoid computing client type ever and ever) ?
    Fr?d?ric
    PS: James Baty will confirm I'm not cheap ;?)
    On mercredi, nov 13, 2002, at 21:11 Europe/Paris, Craig V. Conover
    wrote:
    Fr?d?ric
    Is there anyway that we could talk with you about your WML efforts with
    JATO?
    I would love to get a sample WML app to show the world. And then have a
    WML/HTML app to show multiple clients using the same ViewBeans.
    craig
    Fr?d?ric Miserey wrote:
    On mercredi, nov 13, 2002, at 13:34 Europe/Paris, Todd Fast wrote:
    Fr?d?ric--
    Thanks for the info; I will look into a way of doing something
    about
    this.
    However, please keep in mind that you can write your own complementary
    tags
    to render JATO components any way you like (or write JATO components
    that
    render themselves any way you like), and this is expected to be a
    normal, if
    infrequent, part of writing JATO 2.0 components.That's what I'm doing right now for the WML tags. But I was planning on
    using the standard tags for mainstream HTML ;)
    May you elaborate a little bit on complementary tags vs components ?
    (first part of the suggested thread.
    Until the 2.0 taglib is documented, you can use the 1.2.1 JATO
    source
    to
    guide this effort.? It's actually pretty easy, but you will need the
    source
    to guide you without docs to that effect.? You can download the JATO
    1.2.1
    source, free of charge, etc. here:
    ???? http://iplanet.com/downloads/developer/5102.html
    (If that doesn't work, just do a search for "JATO" on sun.com).? We
    can also
    start a tag-writing thread here if you like.
    I would love to get your perspective on any XHTML shortcomings of the
    current tag library.? Can you plase send your thoughts, list of
    issues, etc.
    to jatoteam@e...?you don't know what you've just asked ;)
    Todd
    ----- Original Message -----
    From: "Fr?d?ric Miserey" <frederic@n...>
    Sent: Tuesday, November 12, 2002 8:35 AM
    Subject: [SunONE-JATO] yet more TagLibs problems
    As jato2 still doesn't know about some HTML4 tags like <label>
    ex:
    <label><input type="radio" ... />TheLabel</label>
    if you click on "TheLabel", it clicks on the radio button, like
    every
    other GUI
    I thought I would be able use the <label for="">? as a workaround
    <input type="radio" name="choice" id="choice1" /> <label
    for="choice1">TheLabel</label>
    BUT despite it generates several tags, <jato:radioButtons> sets the id
    attribute to the same value for every tag :< This not only defeats my
    workaround but also id main purpose to uniquely identity elements.
    We really need a generic mechanism to specify attributes when jato tags
    generate multiple HTML tags.
    I can still change the generated tags in endDisplay but it be neat if
    the 201 taglib was a little bit more XHTML compliant and savvy ;)
    Fr?d?ric
    ps: release this part of the source code and we'll do it !
    [Non-text portions of this message have been removed]

  • Bizarre thread problem with JSP

    I'm having a strange problem using JSPs whereby a single method call to a
              bean results in 2 execute threads being created each executing the method
              called.
              I have a bean reference in the jsp that has session scope declared like this
              (package names left off):
              <jsp:useBean id="deployment" class="Deployment" scope="session">
              <% deployment.init(application); %>
              </jsp:useBean>
              I've also set the isThreadSafe value to "false" (since I'm trying to
              prevent/figure out what's going on):
              <%@ page isThreadSafe="false" %>
              Within the JSP body I have code that makes the method call on the deployment
              bean:
              if (action.equals("Send"))
              int status = deployment.send();
              Then, within my form I have:
              <INPUT TYPE="image" SRC="../images/Deploy.gif"
              onClick="confirmAndSubmit('Send',
              'Deploying Application to server <%=
              deployment.getServer() %>')"/>
              Where the functions called are:
              function setActionSubmit(action) {
              document.deployForm.actionPerformed.value = action;
              document.deployForm.submit();
              function confirmAndSubmit(action, promptString) {
              if (confirm(promptString)) {
              setActionSubmit(action);
              Tracing, thread dumping, et al, have confirmed that although I have a single
              session, I end up with two threads each executing the deployment.send()
              method.
              Any ideas? I'm stumped.
              Thanks,
              Jim
              

    I found the problem, although I don't completely understand the behavior:
              The FORM was not handling the submit event, leaving it to the whim of the
              browser to have its way with the event. Although it sometime ended up
              having two threads serving the request, it didn't always.
              The solution was to put an onSubmit=="return false;" in the <form>
              Hope this helps someone else.
              Jim
              "Jim Gish" <[email protected]> wrote in message
              news:[email protected]...
              > I'm having a strange problem using JSPs whereby a single method call to a
              > bean results in 2 execute threads being created each executing the method
              > called.
              >
              > I have a bean reference in the jsp that has session scope declared like
              this
              > (package names left off):
              >
              > <jsp:useBean id="deployment" class="Deployment" scope="session">
              > <% deployment.init(application); %>
              > </jsp:useBean>
              >
              > I've also set the isThreadSafe value to "false" (since I'm trying to
              > prevent/figure out what's going on):
              > <%@ page isThreadSafe="false" %>
              >
              > Within the JSP body I have code that makes the method call on the
              deployment
              > bean:
              > if (action.equals("Send"))
              > {
              > int status = deployment.send();
              > }
              >
              > Then, within my form I have:
              > <INPUT TYPE="image" SRC="../images/Deploy.gif"
              > onClick="confirmAndSubmit('Send',
              > 'Deploying Application to server <%=
              > deployment.getServer() %>')"/>
              >
              > Where the functions called are:
              > function setActionSubmit(action) {
              > document.deployForm.actionPerformed.value = action;
              > document.deployForm.submit();
              > }
              >
              > function confirmAndSubmit(action, promptString) {
              > if (confirm(promptString)) {
              > setActionSubmit(action);
              > }
              > }
              >
              > Tracing, thread dumping, et al, have confirmed that although I have a
              single
              > session, I end up with two threads each executing the deployment.send()
              > method.
              >
              > Any ideas? I'm stumped.
              >
              > Thanks,
              > Jim
              >
              >
              >
              >
              >
              

  • Apache/Jserv Config Problem with JSP

    Problem: Any JSP that contains a bean reference is not being loaded correctly.
    The first thing I did was to create a softlink from the ".../Apache/Apache/htdocs" directory to
    the directory which contains my *.html and *.jsp files (as instructed in the httpd.conf file).
    Then, I followed the instructions on page A-9 of "OracleJSP Developer's Guide and
    Reference, Release 1.1.0.0.0". They instruct you to add a wrapper.classpath entry into
    jserv.properties that points at your directory that contains the .class files for your bean
    classes. I did this too.
    I then attempted to load my JSP file from the browser URL entry line. If my JSP does not contain
    a reference to a bean, then the page loads fine. If it contains a reference to a bean, then I
    get the following message:
    Request URI:/webdocs/vps/hellouser/hellouser.jsp
    Exception:
    oracle.jsp.parse.JspParseException: Line # 4, Error: Unable to find class for bean: myBean defined
    by tag with class: hello.NameHandler
    I cannot for the life of me get Apache to look in one directory for the .jsp file and another for
    the .class file(s). Any suggestions would be greatly appreciated!
    MORE BACKGROUND:
    If it matters..... My first venture was servlets and I've managed to workt that just fine: I
    successfully modified "jserv.conf" to add a mount point (ApJServMount) for my new servlet zone
    which I have specified in "jserv.properties". I have also created an associated properties file
    for my new servlet zone. I've tested this configuration and all works fine for servlets, just not
    JSP.
    Once again, thanks in advance for any help regarding a solution to this problem!!!
    Dave

    Problem: Any JSP that contains a bean reference is not being loaded correctly.
    The first thing I did was to create a softlink from the ".../Apache/Apache/htdocs" directory to
    the directory which contains my *.html and *.jsp files (as instructed in the httpd.conf file).
    Then, I followed the instructions on page A-9 of "OracleJSP Developer's Guide and
    Reference, Release 1.1.0.0.0". They instruct you to add a wrapper.classpath entry into
    jserv.properties that points at your directory that contains the .class files for your bean
    classes. I did this too.
    I then attempted to load my JSP file from the browser URL entry line. If my JSP does not contain
    a reference to a bean, then the page loads fine. If it contains a reference to a bean, then I
    get the following message:
    Request URI:/webdocs/vps/hellouser/hellouser.jsp
    Exception:
    oracle.jsp.parse.JspParseException: Line # 4, Error: Unable to find class for bean: myBean defined
    by tag with class: hello.NameHandler
    I cannot for the life of me get Apache to look in one directory for the .jsp file and another for
    the .class file(s). Any suggestions would be greatly appreciated!
    MORE BACKGROUND:
    If it matters..... My first venture was servlets and I've managed to workt that just fine: I
    successfully modified "jserv.conf" to add a mount point (ApJServMount) for my new servlet zone
    which I have specified in "jserv.properties". I have also created an associated properties file
    for my new servlet zone. I've tested this configuration and all works fine for servlets, just not
    JSP.
    Once again, thanks in advance for any help regarding a solution to this problem!!!
    Dave

  • Jsp taglib problems in J2ee server  of j2sdkee1.3

    Fresh from solving the problems with usebean in jsp, I again got a problem with the custom tags of JSP
    I am using Jdk1.3 and j2sdkee1.3, windows98
    The class file is stored in a package called my in the c:\j2sdkee1.3\lib\classes\my folder
    and the tld and jsp file stored in c:\j2sdkee1.3\public_html folder
    when I access the atm.jsp page, I got this error message
    A Servlet Exception Has Occurred
    org.apache.jasper.compiler.ParseException: End of content reached while more parsing required: tag nesting error?
    Here is the ATMJsp.tld code
    <?xml version="1.0" encoding="ISO-8859-1" ?>
    <!DOCTYPE taglib PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.1//EN" "http://java.sun.com/j2ee/dtds/web-jsptaglibrary_1_1.dtd">
    <taglib>
         <tlibversion>1.0</tlibversion>
         <jspversion>1.1</jspversion>
         <shortname>ATMJsp</shortname>
         <info>a tag library for the atm details</info>
         <tag>
              <name>ATM</name>
              <tagclass>my.atmtag</tagclass>
              <bodycontent>JSP</bodycontent>
              <info>Outputs of the ATM Counter</info>
         </tag>
    </taglib>
    I try:
    When I put the <bodycontent> tags below the <info> tags, I got the error message that the tag doesn't allow "bodycontent" here
    I don't know what caused the problem ... is there some mistake in the above code?
    Include other file to make it more clear---* atm.jsp and atmtag.java
    atm.jsp
    <%@ page import="my.atmtag" %>
    <%@ taglib uri="ATMJsp.tld" prefix="atmjsp" %>
    <%@ page errorPage="errorpage.jsp" %>
    <!DocType HTML Public "-//W3C//DTD// HTML 4.0 Translational//EN">
    <html>
    <head></head>
    <body>
    <h3 align=center>ATM counters that need cash</h3>
    <table><tr>
    <td></td>
    <td><atmjsp:ATM></td>
    </tr>
    </body>
    </html>
    atmtag.java
    package my;
    import javax.servlet.jsp.*;
    import javax.servlet.jsp.tagext.*;
    import java.io.*;
    import java.sql.*;
    import java.math.*;
    import java.util.*;
    //tag handler
    public class atmtag extends TagSupport
         Connection connect=null;
         Statement state=null;
         ResultSet result=null;
         public atmtag() throws ClassNotFoundException
              Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
         public int doStartTag() throws JspTagException
              return EVAL_BODY_INCLUDE;
         public int doEndTag() throws JspTagException
              try
                   JspWriter out=pageContext.getOut();
                   connect=DriverManager.getConnection("jdbc:odbc:EarnestBank","","");
                   String strquery="select cCounter_id, cAddress, mCashBalance from Counter where mCashBalance<=10000";
                   state=connect.createStatement();
                   ResultSet result=state.executeQuery(strquery);
                   String sid=null;
                   String saddress=null;
                   String sbalance=null;
                   Vector v=new Vector();
                   while(result.next())
                        sid=result.getString(1);
                        saddress=result.getString(2);
                        sbalance=result.getString(3);
                        v.add(sid);
                        v.add(saddress);
                        v.add(sbalance);
                   for (int i=0; i<v.size();i++)
                        String str=(String)v.elementAt(i);
                        pageContext.getOut().write(str);
              catch(Exception ex)
              return EVAL_PAGE;
    Pls help me to get through this hurdle
    Thanks

    1) To handle <bodycontent> you should inherit from BodyTagSupport
    class
    2) You should use your bean like: <td><atmjsp:ATM/></td>
    with closing slash - it's bodyless tag - this mistake
    causes JSP compiler to report error
    Enjoy!
    Paul

  • Jsp taglib problem

    Hello all,
    as i am facing problem to display the value inside the table. following are the flow files of my code.
    my jsp page............
    <%@ taglib uri="/WEB-INF/tld/c.tld" prefix="c" %>
    <tr>
    <td> </td>
    <td nowrap><b>Client</b></td>
    <td><c ut value="${ConstantDeclarations.ATTR_CMB_CLIENT.strClientName}" default="value is null" escapeXml="true"/></td>
    <!--<td><label for="<%=ConstantDeclarations.ATTR_CMB_CLIENT%>"><%=strClientName%></label></td>-->
    <td> </td>
    </tr>
    my c.tld file.....................
    <tag>
    <description>
    Like <%= ... >, but for expressions.
    </description>
    <name>out</name>
    <tag-class>org.apache.taglibs.standard.tag.rt.core.OutTag</tag-class>
    <body-content>JSP</body-content>
    <attribute>
    <description>
    Expression to be evaluated.
    </description>
    <name>value</name>
    <required>true</required>
    <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
    <description>
    Default value if the resulting value is null.
    </description>
    <name>default</name>
    <required>false</required>
    <rtexprvalue>true</rtexprvalue>
    </attribute>
    <attribute>
    <description>
    Determines whether characters <,>,&,'," in the
    resulting string should be converted to their
    corresponding character entity codes. Default value is
    true.
    </description>
    <name>escapeXml</name>
    <required>false</required>
    <rtexprvalue>true</rtexprvalue>
    </attribute>
    </tag>
    so i am trying to display the value ConstantDeclarations.ATTR_CMB_CLIENT.strClientName in the table which is taking from the class file ProjectVO.class. in which getClientName is returning the value of strClientName. as shown below
    public class ProjectVO extends ValueObjectImpl implements SearchableEntity{
    public String getClientName(){
    return strClientName;
    i have tried different types like
    ProjectVo.ATTR_CMB_CLIENT.strClientName
    ProjectVO.getClientName.strClientName
    so please refer the code and if u have any solution for this reply to me.
    with regards
    seenu

    First, next time you post code, could you please use [code] tags as per the [code] button at the top of the posting page...
    Okay, down to the question. You have this:
    ${ConstantDeclarations.ATTR_CMB_CLIENT.strClientName}
    This will look for a variable instance named ConstantDeclarations and will try to access the method:
    public [ObjectType] getATTR_CMB_CLIENT()
    It will then try to call
    public [ObjectType] getStrClientName()
    from the object returned from the previous method call.
    The point is: ConstantDeclarations can not be a class name, it must be an instance of a class. And ATTR_CMB_CLIENT can not be a static member of that class. It must be a property - accessed through a getATTR_CMB_CLIENT() method, which must be public, non static, and have a return type (non-void).

  • Problem compling JSP with struts tags on Weblogic 8.1

    I have deployed a web application in Weblogic 8.1. However, I am facing a problem while the JSPs are getting compiled. The JSPs ahve taglib declarations referring to Struts tag library files that are present in WEB-INF folder.
    Stacktrace:
    C:\java\bea\user_projects\domains\mydomain\.\myserver\.wlnotdelete\extract\myserver_epgonline_epgonline\jsp_servlet\_approve\__approve_home.java:209: cannot resolve symbol
    probably occurred due to an error in /approve/approve_home.jsp line 53:
    <logic:notPresent name="<%=JobBean.ID%>" scope="request">
    C:\java\bea\user_projects\domains\mydomain\.\myserver\.wlnotdelete\extract\myserver_epgonline_epgonline\jsp_servlet\_approve\__approve_home.java:209: cannot resolve symbol
    symbol : variable EVAL_BODY_BUFFERED
    location: interface javax.servlet.jsp.tagext.BodyTag
    if (_int0 == BodyTag.EVAL_BODY_BUFFERED) { //[ /approve/approve_home.jsp; Line: 53]
    I believe other people have also faced this issue with Weblogic8.1 and struts. Any solutions???
    Thx
    KP

    KP,
    Does this code run in the development environment but not in production? How
    was this code compiled?
    - john
    "KP" <[email protected]> wrote in message
    news:405b9b56$[email protected]..
    I have deployed a web application in Weblogic 8.1. However, I am facing aproblem while the JSPs are getting compiled. The JSPs ahve taglib
    declarations referring to Struts tag library files that are present in
    WEB-INF folder.
    Stacktrace:
    C:\java\bea\user_projects\domains\mydomain\.\myserver\.wlnotdelete\extract\m
    yserver_epgonline_epgonline\jsp_servlet\_approve\__approve_home.java:209:
    cannot resolve symbol
    probably occurred due to an error in /approve/approve_home.jsp line 53:
    <logic:notPresent name="<%=JobBean.ID%>" scope="request">
    C:\java\bea\user_projects\domains\mydomain\.\myserver\.wlnotdelete\extract\m
    yserver_epgonline_epgonline\jsp_servlet\_approve\__approve_home.java:209:
    cannot resolve symbol
    symbol : variable EVAL_BODY_BUFFERED
    location: interface javax.servlet.jsp.tagext.BodyTag
    if (_int0 == BodyTag.EVAL_BODY_BUFFERED) { //[/approve/approve_home.jsp; Line: 53]
    >
    I believe other people have also faced this issue with Weblogic8.1 andstruts. Any solutions???
    >
    Thx
    KP

  • Paging problem in jsp

    Just 3 jsp's. The first page is the basic form that posts to the results.jsp page. The problem is in the results.jsp page. I get the first 20 like I want, but after I click next. I get "exhausted resultset". I don't know what that means exactly. I checked to see how many results I get back, and its 444. I would appreciate any help.
    I also need to sort the results by column name in the jsp later, but this is my immediate need.
    results.jsp
    <%@page contentType="text/html"%>
    <%@page pageEncoding="UTF-8"%>
    <%@ page import="java.sql.*" %>
    <%@ page import="db.DB" %>
    <%
        int currentRow = 1;
        if(request.getParameter("currentRow") != null)
            currentRow = Integer.parseInt(request.getParameter("currentRow"));
        int skipRows = 20;
        System.out.println("Current currentRow: " + currentRow);
        String action = "";
        if(request.getParameter("action") != null)
            action = request.getParameter("action");
        if ( action.equals("Next Record") )
            currentRow += skipRows;
        if ( action.equals("Previous Record") )
            currentRow -= skipRows;
    %>
    <HTML>
    <HEAD>
    <TITLE>Bidder Results </TITLE>
    </HEAD>
    <BODY>
    <H1>Bidder Results </H1>
    <FORM ACTION="resultsjsp" METHOD="POST">
    <%
        String category =request.getParameter("category");
        DB db = new DB();
        Connection conn = null;
        Statement st = null;
        ResultSet rs = null; 
        conn = db.getConnection();
        String query1 = "SELECT BDR_NUM, BDR_NME, BDR_CITY, BDR_ST, BDR_BUS_CAT1 FROM T01_MINOR " +
                        "WHERE trim(BDR_BUS_CAT1) = '" + category + "'" + "ORDER BY BDR_NME";
        st = conn.createStatement(rs.TYPE_SCROLL_INSENSITIVE,
        rs.CONCUR_READ_ONLY);
        rs = st.executeQuery(query1);
        rs.last();
        int totalrows = rs.getRow();
        System.out.println("Total Rows = " + totalrows );
        if ( currentRow >= totalrows )
            currentRow = totalrows-skipRows;
        if ( currentRow < 0 )
            currentRow = 0;
        if ( currentRow != 0 )
            rs.absolute(currentRow);
    %>
    <TABLE BORDER="1" WIDTH="90%">
    <TR>
      <TH>Bidder Name</TH>
      <TH>City</th>
      <TH>State</th>
      <TH>Category</TH>
    </TR>
    <%
        int i=0;
        int count=0;
        boolean next = false;
        do{
        i++;
    %>
        <TR>
            <TD><a href="details.jsp?bidder_id=<%= rs.getString("BDR_NUM") %>"><%= rs.getString("BDR_NME") %></A></TD>
            <TD><%= rs.getString("BDR_CITY") %></TD>
            <TD><%= rs.getString("BDR_ST") %></TD>
            <TD><%= rs.getString("BDR_BUS_CAT1") %></TD>
        </TR>
    <%
        while((next=rs.next()) && i<skipRows);
            count++;
        System.out.println("Count: " + count);
    %>
        </TABLE>
        <BR>
        <INPUT TYPE="HIDDEN" NAME="currentRow" VALUE="<%=currentRow%>">
        <INPUT TYPE="HIDDEN" NAME="action" VALUE="next">
    <%
        if(next)
    %>
            <INPUT TYPE="SUBMIT" NAME="action" VALUE="Next Record">
    <%
        if(currentRow > 0)
        %>
            <INPUT TYPE="SUBMIT" NAME="action" VALUE="Previous Record">
        <%
    %>
    </FORM>
    </BODY>
    </HTML>

    << http://www.fawcette.com/javapro/2002_06/online/servlets_06_11_02/
    Yarmark. I totally agree with you, but my boss who is not a programmer wanted this up yesterday. Also, I do not know taglibs, struts, etc... Right now I only know this way of programming. Now, I plan on taking some struts classes, and may JSF, but I am stuck with writing code that I sort of already know how to write. This is temporary anyway. This is just a little demo for my boss's bosses. He just wants to show them the functionality of it. I can revisit it afterward to make it better. If this demo looks good for my boss, then it looks good for me.

  • Taglib problem: Cannot parse custom tag with short name table

    Hello!
    I am having problems deploying a jsp tag in web as. The same war file works fine on websphere, jboss. SAP web as seems to be complaining about the short name in the tld.
    Can any body me to any known web as issues with jsp tags?
    Thanks
    [code]
    Application error occurs during processing the request.
    Details: com.sap.engine.services.servlets_jsp.server.exceptions.WebIOException: Internal error while parsing JSP page /usr/sap/J2E/JC00/j2ee/cluster/server0/apps/sap.com/dispear/servlet_jsp/disp/root/test.jsp.
         at com.sap.engine.services.servlets_jsp.server.jsp.JSPParser.parse(JSPParser.java:85)
         at com.sap.engine.services.servlets_jsp.server.servlet.JSPServlet.getClassName(JSPServlet.java:207)
         at com.sap.engine.services.servlets_jsp.server.servlet.JSPServlet.compileAndGetClassName(JSPServlet.java:369)
         at com.sap.engine.services.servlets_jsp.server.servlet.JSPServlet.service(JSPServlet.java:164)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:385)
         at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:263)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:340)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:318)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:821)
         at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:239)
         at com.sap.engine.services.httpserver.server.Client.handle(Client.java:92)
         at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:147)
         at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:37)
         at com.sap.engine.core.cluster.impl6.session.UnorderedChannel$MessageRunner.run(UnorderedChannel.java:71)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:94)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:162)
    Caused by: com.sap.engine.services.servlets_jsp.lib.jspparser.exceptions.JspParseException: Cannot parse custom tag with short name table.
         at com.sap.engine.services.servlets_jsp.lib.jspparser.syntax.xmlsyntax.CustomJspTag.action(CustomJspTag.java:129)
         at com.sap.engine.services.servlets_jsp.lib.jspparser.syntax.ElementCollection.action(ElementCollection.java:52)
         at com.sap.engine.services.servlets_jsp.server.jsp.JSPParser.initParser(JSPParser.java:307)
         at com.sap.engine.services.servlets_jsp.server.jsp.JSPParser.parse(JSPParser.java:74)
         ... 18 more
    Caused by: com.sap.engine.services.servlets_jsp.lib.jspparser.exceptions.JspParseException: Unknown class name java.lang.Object.
         at com.sap.engine.services.servlets_jsp.lib.jspparser.taglib.TagBeginGenerator.convertString(TagBeginGenerator.java:365)
         at com.sap.engine.services.servlets_jsp.lib.jspparser.taglib.TagBeginGenerator.generateSetters(TagBeginGenerator.java:187)
         at com.sap.engine.services.servlets_jsp.lib.jspparser.taglib.TagBeginGenerator.generateServiceMethodStatements(TagBeginGenerator.java:212)
         at com.sap.engine.services.servlets_jsp.lib.jspparser.taglib.TagBeginGenerator.generate(TagBeginGenerator.java:269)
         at com.sap.engine.services.servlets_jsp.lib.jspparser.syntax.xmlsyntax.CustomJspTag.action(CustomJspTag.java:127)
         ... 21 more
    [/code]

    Hi Ray,
    I am facing similar kind of issue.
    Can you please help to resolve it?
    Thanks in advance.
    Logs are as below [Here I am using standard tag lib]::
    Caused by: com.sap.engine.services.servlets_jsp.jspparser_api.exception.JspParseException: Cannot parse custom tag with short name [out].
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.xmlsyntax.CustomJspTag.action(CustomJspTag.java:183)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.ElementCollection.action(ElementCollection.java:59)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.JspIncludeDirective.action(JspIncludeDirective.java:51)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.ElementCollection.action(ElementCollection.java:59)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.JspElement.customTagAction(JspElement.java:994)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.JspElement.action(JspElement.java:228)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.ElementCollection.action(ElementCollection.java:59)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.ElementCollection.action(ElementCollection.java:69)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.GenerateJavaFile.generateJavaFile(GenerateJavaFile.java:72)
         at com.sap.engine.services.servlets_jsp.server.jsp.JSPProcessor.parse(JSPProcessor.java:270)
         at com.sap.engine.services.servlets_jsp.server.jsp.JSPProcessor.generateJavaFile(JSPProcessor.java:194)
         at com.sap.engine.services.servlets_jsp.server.jsp.JSPProcessor.parse(JSPProcessor.java:126)
         at com.sap.engine.services.servlets_jsp.jspparser_api.JSPChecker.getClassName(JSPChecker.java:319)
         at com.sap.engine.services.servlets_jsp.jspparser_api.JSPChecker.compileAndGetClassName(JSPChecker.java:248)
         at com.sap.engine.services.servlets_jsp.jspparser_api.JSPChecker.getClassNameForProduction(JSPChecker.java:178)
         at com.sap.engine.services.servlets_jsp.jspparser_api.JSPChecker.processJSPRequest(JSPChecker.java:109)
         at com.sap.engine.services.servlets_jsp.jspparser_api.JspParser.generateJspClass(JspParser.java:154)
         at com.sap.engine.services.servlets_jsp.server.servlet.JSPServlet.service(JSPServlet.java:193)
         ... 47 more
    Caused by: com.sap.engine.services.servlets_jsp.jspparser_api.exception.JspParseException: Attribute [value] of [<c:out>] can accept only static values.
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.taglib.TagBeginGenerator.calculateAttributeValue(TagBeginGenerator.java:476)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.taglib.TagBeginGenerator.generateSetters(TagBeginGenerator.java:394)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.taglib.TagBeginGenerator.generateServiceMethodStatements(TagBeginGenerator.java:562)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.taglib.TagBeginGenerator.generate(TagBeginGenerator.java:678)
         at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.xmlsyntax.CustomJspTag.action(CustomJspTag.java:181)
         ... 64 more
    Regards,
    Sankalp

Maybe you are looking for

  • Time Machine "inherit" after emergency downgrade to Mavericks

    (iMac;  3.6GHz Intel Core i5; 16GB 1333 MHz DDR3 memory) I was having many kernel panics after upgrading to Yosemite. After thorough hardware diagnostics (no hardware problems), the Genius Bar guy suggested downgrading to Mavericks 10.9.5, which he d

  • SAPDB : Archive the Log and Data files

    Hi, I am running a SAP WAS JAVA on my laptop with SAPDB as the database. Its used for my local developments. I have 3 log files and 3 data files of 1 GB each. I want to reduce this to 1 log file and 1 data file to free some space on my Laptop. How ca

  • FB1S - Change Document Date

    Hello ABAP experts I've been asked by our client to make a modification when posting open items through txn FB1S (or in their case F-03).  When posting a document through this txn, the document date is set as equal to the posting date.  The users wan

  • Windows 8 Brightness Issue.

    Hi everybody, im running OSX 10.7.5 Lion with Bootcamp 4.0.4 on my MBP (late 2011, i7, 15"). Recently i upgraded my windows 7 to windows 8. and downloaded bootcamp 4.0 via TPB (since Apple didnt have the drivers on their website). Everything installe

  • Urgent - Big POC: SAP Adapter Java API !

    Hi, I'm trying to get from an SAP BAPPI values using SAP Adapter Java API. I had tested at BEA and it worked fine. the code is: try { InitialContext ic = new InitialContext(env); // Create an object that provides the services established during confi