Tomcat error pages

How can i define my own jsp error pages, and how do i suse them after defining them?
thanks

errorPage attribute specifies a JSP page that should process exceptions that are thrown but not caught by the current page.
<% page errorPage="Relative URL" %>
There is also the isErrorPage attribute.
This indicates whether or not the current page can act as an error page for another JSP page.
<% page isErrorPage="true" %>
<% page isErrorPage="false" %><%-- this is the default --%>
Sooooo as an example...
You are in a JSP page and an error is generated. You have indicated already that if an error is generated oin this page you should go to the Error JSP page.
--- Inside of "someCalculation.jsp" ---
<% page errorPage="iamTheJSPErrorPage.jsp" %>
--- Inside of "iamTheJSPErrorPage.jsp" ---
<% page isErrorPage="true" %>
Remember that these are relative URLs that are requried. So if you have your Error page in another directory, you must reflect that in your URL.
Hope that helps

Similar Messages

  • JSP error page does not displayed on its own, includes in the original JSP

    Problem Description: - Exceptions in a Condition cause pages to fail to render.
    The actual issue is, the JSP error page does not displayed on its own, included in the original JSP Page when exception occurs.
    Problem Cause: As per the JSP specification when jsp content reached the buffer size (default 8KB) the page being flushed (Part of condent displays). The default �autoFlush� value is true.
    When the page buffer value is default size (8KB), and if any exception occurs after flushing the part of the content, instead of redirecting into error page, the error page content included in the original page.
    If i specify autoFlush="false" and with default buffer size, at the runtime if the buffer size is reached, i am getting stackoverflow error.
    To solve the above problem we can make it autoFlush=�false� and buffer=�100KB�. But we can�t predict the actual size of the page.
    I found in one of the weblogic forum as no solution for this issue. Ref.
    http://support.bea.com/application?namespace=askbea&origin=ask_bea_answer.jsp&event=link.view_answer_page_clfydoc&answerpage=solution&page=wls/S-10309.htm
    Please provide me any solution to resolve the problem.

    Error-Page tags work best with an error.html pages. If you have an error.jsp page what I would do, and I have, is wrap my classes and jsp pages in a try catch block where you forward to the error jsp page and display anything you want. YOu can also do this with if else statements. I have used the tomcat error pages before but when I've implemented them I used java.lang.Exception as the error to catch not Throwable. I don't know if this would make a difference or have anything to do with your problem.

  • Customised Error Pages

    Hi
    Im just wondering how easy it is to create customised pages in JSP.
    For example I have a registration page on my website. I have registered with the usrername jbloggs. If another user tries to register after me with the same username they will get a Tomcat error page or a bad gateway. I want to be able to display a page that says something like "Username jbloggs has already been chosen. Please chose another username". Does anybody have any idea how to do this.
    Thanks
    Damul

    Your code has to detect a user has registered with the same username.
    I presume you are using a database?
    So you can do this pre-emptively. Check if the username exists before entering.
    Or you can just let it enter, and (presumably) catch the SQLException caused when you try and enter duplicate values (thats if you have the constraint on the database of course)
    In either case, you catch the exception in java code, and can use the RequestDispatcher to forward to any page you like.
    Cheers,
    evnafets
    Cheers,
    evnafets

  • The custm error page is not getting loaded in TomCat 5.0

    Hi all,
    I am working on a JSF web application deployed in Tomcat 5.0.I was trying to redirect 404 and 500 error pages to custom error pages.But the error pages are not getting loaded and i am getting normal Tocat 404 status page.
    I am giving the web.xml entry for the error page defenition.
    <error-page>
              <error-code>404</error-code>
              <location>/faces/displayErrorpage.jsp</location>
         </error-page>
         <error-page>
              <error-code>500</error-code>
              <location>/faces/SessionExpirepage.jsp</location>
         </error-page>
         <error-page>
              <exception-type>java.lang.Throwable</exception-type>
              <location>/faces/displayErrorpage.jsp</location>
         </error-page>
    Please help me out to solve this problem.Its urgent.I will be greatful for any kind of help.
    Note: The same application working fine,ie,the error page is getting loaded while deploying WAS 6.0.
    Jeevan Edakkunnath.

    That's a specification version. I was asking for the implementation and version. Is it the Sun reference implementation (Sun JSF RI)? If so, which build?
    It works flawlessly here on the latest build of Sun JSF RI 1.1, the 1.1_02. You can get the latest build at [http://javaserverfaces.dev.java.net]. I was using Tomcat 6.0.14 by the way, it might make difference.
    Does it work if you use plain vanilla JSP files and do not pass the request through the FacesServlet? I recall some bugs related to it, but I am not sure anymore if it is related to the JSF implementation or application server used.

  • Error-page problem with Tomcat 5.0.24

    I want to display an error page in case any exception is thrown by my JSF application.
    I configure the error page in the web.xml and run the application on Tomcat 5.0.24.
    When an error really happens while loading a jsf-page A the error page is not displayed. In IE i see just a blank page. When I check the source code it shows me some parts of the page A (javascript functions). So it actually never navigates to the error page.
    I tried to use jsf, simple jsp or even html pages as an error page - the same effect.
    And one more thing. When plain jsp-page throws an exception I see my error page all right. Also I see an exception stack trace in Tomcat console. When jsf-page throws an exception I don't see any exception information in the Tomcat console.
    Does anybody has an explanation to this? Can anybody recommend me any other way to watch for exceptions in a JSF-application?
    Any help will be appreciated.
    Slawa

    I resolved the problem.
    I had to increase the jsp-buffer size for the erroneous page. It looks like it started to load and when the error happened the container couldn't redirect to the error page.
    Thanks to jBoss which gives more log messages though is also based on tomcat.
    Slawa

  • Error page redirection in tomcat 4.1

    Hi,
    I have error page directive in web.xml as follows
    <error-page>
    <exception-type>javax.servlet.ServletException</exception-type>
    <location>/jsp/system_error.jsp</location>
    </error-page>
    But tomcat wouldnt show up this page. But this very same application would work fine when I invoke tomcat using my netbeans IDE. wouldnt work with a standalone tomcat. any clues?

    Hi,
    Yes that's a bug/feature of tomcat 4.1. You need to declare a Logger in your tomcat server configuration file :
    <?xml version="1.0" encoding="UTF-8"?>
    <Server debug="0" port="8084" shutdown="SHUTDOWN">
      <Service name="Tomcat-Standalone">
        <Connector acceptCount="10" className="org.apache.coyote.tomcat4.CoyoteConnector" connectionTimeout="60000" debug="0" maxProcessors="75" minProcessors="5" port="8083"/>
        <Engine debug="0" defaultHost="localhost" name="Standalone">
          <Logger className="org.apache.catalina.logger.SystemOutLogger"/>
          <Host appBase="C:\Tomcat\webapps" debug="0" name="localhost" unpackWARs="true"/>
        </Engine>
      </Service>
    </Server>

  • Tomcat, custom error page, sendError and encoding problems

    Hi All!
    I have the following code in my index.jsp page:
    <%
        if(hasParent && !imageStore.contains(parent))
            response.sendError(404, "Requested image with id=" + parent + " was not found on this server");
            return;
    %>following in the web.xml:
    <error-page>
        <error-code>404</error-code>
        <location>/404.jsp</location>
    </error-page>Both pages (index.jsp and 404.jsp) are windows-1251 encoded:
    <%@page contentType="text/html; charset=windows-1251"%>But I have an issue: all non-latin characters are mangled when 404.jsp displayed as the result of calling response.sendError.
    I mean, if I open myserver.com/404.jsp or myserver.com/non-existing-document-la-la-la, everything is okay. But when I open myserver.com/index.jsp?parent=123 it calls response.sendError - text is mangled.
    What's even more bizarre, Tomcat sends the right encoding in the response headers, but with ? instead non-latin characters:
    HTTP request sent, awaiting response...
    1 HTTP/1.1 404 Requested image with id=1231231 was not found on this server
    2 Content-Type: text/html;charset=windows-1251
    3 Date: Sat, 16 Sep 2006 18:14:27 GMT
    4 Server: Apache-Coyote/1.1
    5 Connection: Keep-Alive
    22:14:27 ERROR 404: Requested image with id=1231231 was not found on this server
    .I am using Apache Tomcat/5.0.28.
    I understand that this issue is not trivial, but I would appreciate any ideas.

    Hi All!
    I have the following code in my index.jsp page:
    <%
        if(hasParent && !imageStore.contains(parent))
            response.sendError(404, "Requested image with id=" + parent + " was not found on this server");
            return;
    %>following in the web.xml:
    <error-page>
        <error-code>404</error-code>
        <location>/404.jsp</location>
    </error-page>Both pages (index.jsp and 404.jsp) are windows-1251 encoded:
    <%@page contentType="text/html; charset=windows-1251"%>But I have an issue: all non-latin characters are mangled when 404.jsp displayed as the result of calling response.sendError.
    I mean, if I open myserver.com/404.jsp or myserver.com/non-existing-document-la-la-la, everything is okay. But when I open myserver.com/index.jsp?parent=123 it calls response.sendError - text is mangled.
    What's even more bizarre, Tomcat sends the right encoding in the response headers, but with ? instead non-latin characters:
    HTTP request sent, awaiting response...
    1 HTTP/1.1 404 Requested image with id=1231231 was not found on this server
    2 Content-Type: text/html;charset=windows-1251
    3 Date: Sat, 16 Sep 2006 18:14:27 GMT
    4 Server: Apache-Coyote/1.1
    5 Connection: Keep-Alive
    22:14:27 ERROR 404: Requested image with id=1231231 was not found on this server
    .I am using Apache Tomcat/5.0.28.
    I understand that this issue is not trivial, but I would appreciate any ideas.

  • Problem accessing exception object in jsp error page - Apache Tomcat 5.0.25

    Hi all,
    I'm thoroughly confused and need some help. I've deployed a very simple web application in Apache Tomcat 5.0.25 to test exception handling - errortest.jsp and error.jsp. errortest.jsp throws a divide by zero exception if executed with default values in text fields.
    When I put the directive IsErrorPage="true" in error.jsp i get a HTTP 500 error when error.jsp is accessed. If I remove it error.jsp is displayed but I cant access the exception object - if I try to I get an exception below:
    org.apache.jasper.JasperException: Unable to compile class for JSP
    An error occurred at line: 5 in the jsp file: /error.jsp
    Generated servlet error:
    [javac] Compiling 1 source file
    E:\Apache Software Foundation\Tomcat 5.0\work\Catalina\localhost\mywebapp\org\apache\jsp\error_jsp.java:46: cannot resolve symbol
    symbol : variable exception
    location: class org.apache.jsp.error_jsp
    out.print(exception.getMessage());
    ^
    1 error
    Below is the code for the two jsp pages:
    errortest.jsp:
    <%@ page errorPage="error.jsp" %>
    <html>
    <head><title>Error test</title></head>
    <body>     
         <form action="errortest.jsp" method="post">
         Enter first number:<input type="text" name="first" value="5"/><br>
         Enter second number:<input type="text" name="second" value="0"/><br>
         <input type="submit"/>
         </form>
         <%
         if (request.getMethod().equals("POST")) {
              int first = Integer.parseInt( request.getParameter( "first" ) );
              int second = Integer.parseInt( request.getParameter( "second" ) );
              int answer = first/second;
         %>
    </body>
    </html>
    NB: I am able to catch and display the exception if I use a try/catch block around the division as shown below.
    try {
    int answer = first/second;
    } catch( Exception e) {
    e.printStackTrace( new PrintWriter(out) );
    error.jsp (first draft)
    NB: HTTP 500 error occurs when directive "isErrorPage" is added:
    <%@ page isErrorPage="true" %>
    <html>
    <head><title>Error Page</title></head>
    <body>
    </body>
    </html>
    error.jsp (second draft)
    NB: directive is removed but exception thrown when implicit exception object is accessed. error.jsp displays if exception object is not accessed:
    <%@ page %>
    <html>
    <head><title>Error Page</title></head>
    <body>
    <%=exception.getMessage()%>
    </body>
    </html>
    Web server specs:
    Apache Tomcat 5.0.25
    Machine specs:
    Windows XP Pro
    Java environments:
    j2sdk1.4.2_03
    J2EE 1.4

    This works for me:
    throwError.jsp
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
         "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <%@ page language="java" errorPage="/error.jsp"
    contentType="text/html; charset=utf-8" %>
    <html>
    <head>
         <title>Throw Exception</title>
    </head>
    <body>
    Throwing exception....
    <%
    // throw ArithmeticException
    int badInt = 12/0;
    %>
    </body>
    </html>
    error.jsp
    <%@ page language="java" isErrorPage="true" %>
    <head><title>Doh!</title></head>
    An Error has occurred in this application.
    <% if (exception != null) { %>
    <pre><% exception.printStackTrace(new java.io.PrintWriter(out)); %></pre>
    <% } else { %>
    Please check your log files for further information.
    <% } %>

  • Displaying JSP error page in tomcat 5.5.7

    I'm using tomcat 5.5.7 with JDK1.4.1. I've created these 2 JSPs:
    index.jsp:
    <html>
    <title>Jsp</title>
    <body>
    <%@page errorPage="/error.jsp"%>
    Trying to write some error
    <% String butt = request.getParameter("butt");
    if (butt!=null )
       int p = 4/0;
    }%>
    <form method="post">
    <input type="submit" name="butt" value="head">
    </form></body></html> error.jsp:
    <html>
    <title>Jsp</title>
    <body>
    <%@ page isErrorPage="true" %>
    Error Body
    </body></html> When I run this JSP, and try to get the error page, I get internal
    server error page, insteaof of error.jsp.
    The error_jsp.java file has the following lines:
    Throwable exception =
    org.apache.jasper.runtime.JspRuntimeLibrary.getThrowable
    (request);
    if (exception != null) {
    response.setStatus
    (HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
    } I tried to run these same files in Tomcat 4.1, and they work fine.
    What my be the problem? How can I have my error page be displayed?

    Hi,
    I do use Tomcat with the compatibility package (jmx.jar under $CATALINA_HOME/bin and xercesImpl.jar under $CATALINA_HOME/common/endorsed).
    I've put a System.out.println in the error.jsp, and it was printed to the stdout.log.
    Nothing else was printed to the log.
    I also tried removing the isErrorPage="true" from the error page, and I got it displayed (when the error occured). But of course that way I would not have any exception object....

  • How to log in Tomcat administration page

    downloaded apache-tomcat-6.0.10
    OS:window xp
    Tomcat's servlets/JSPs execute fine, but Tomcat denies access to the Tomcat Manager, Tomcat Administration to log in for web application with database connection.
    The respective webapps and manager.xml and admin.xml are available and seem to look fine.
    Tomcat even seems to log in my default user
    tomcat and password tomcat or admin | admin .
    error message;invalid user and password.
    how can I log in?

    i]I edit tomcat-user [roles=manager, admin  user name:admin password:admin] I am sure tomcat-user.xml is correct
    would see the following error message after try to log in tomcat admin page, it happens not only this computer but also my laptop
    type Exception report
    message
    description The server encountered an internal error () that prevented it from fulfilling this request.
    exception
    org.apache.jasper.JasperException: Exception in JSP: /index.jsp:16
    13: <% AccessDB accessDB=new AccessDB(); %>
    14:
    15: <%-- create an instance of List, then retrieve SubjectNames --%>
    16: <% List subjNames=accessDB.getSubjectName(); %>
    17:
    18: <%-- make list accessible to page --%>
    19: <% request.setAttribute("subjNames", subjNames); %>
    Stacktrace:
         org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:504)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
    root cause
    java.lang.NullPointerException
         org.AccessDB.getSubjectName(AccessDB.java:82)
         org.apache.jsp.index_jsp._jspService(index_jsp.java:54)
         org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
    note The full stack trace of the root cause is available in the Apache Tomcat/5.5.17 logs.

  • Problem in Jsp Error page mechanism

    Hi every body,
    In my Jsp application I do some processing within scriplet tags. I have defined a error page using a page directive and I have defined my Error page separately. When there is an exception in a Jsp page, some times it calls the error page properly and displays it. But curiously in some occasions when there is an exception it doesn't call the error page, instead it includes the content of the Error page at the end of the same page, where the exception occurred. The web server is jakarta-tomcat-3.2.1. Can any one who has a idea about this problem help me. Your help is greatly appreciated.
    Thank you

    Hi there!
    Well I was having the same problem as yours until I realized what was going on: the jsp writer has a small buffer size (by default 8kb) and that is why it flushes some html before displaying the error page. The jsp writer buffer is full before getting the exception, so it flushes the buffer and keeps on writing until the exception is thrown. Then the jsp writer writes the error page code...
    You have to add some new parameters in your page directive: autoFlush(true or false) and buffer="16kb" (as much kbytes as you want). For example,
    <%@page autoFlush="false" buffer="sizekb".... %>
    If autoFlush="false", the jsp writer has not finished and the buffer is full an exception will be thrown.
    If autoFlush="true" and the buffer is full it will flush the buffer and so on.
    In both cases, if the buffer size is big enough the error jsp page will be the only displayed
    Good luck!
    Inaki

  • error-page not working in J2EE SDK 5 Update 1

    I recently migrated from Tomcat 5 to J2EE SDK 5 Update 1, and since, have not been able to get my custom error page working. I have verified the path to the error page by testing the link directly in a browser, but still see the default gray and white error page anytime an error occurs. This exact xml worked perfectly in tomcat 5 - am I missing something?
    I have the following in my web.xml:
      <!-- Http error -->
      <error-page>
        <error-code>500</error-code>
        <location>/error.faces</location>
      </error-page>
      <!-- java exception -->
      <error-page>
        <exception-type>java.lang.Exception</exception-type>
        <location>/error.faces</location>
      </error-page>
      <!-- page not found -->
      <error-page>
        <error-code>404</error-code>
        <location>/error.faces</location>
      </error-page>

    Hi, Here is a link from Mozilla that addresses this : http://support.mozilla.com/en-US/kb/Managing+the+Flash+plugin
    Page down to "Flash does not work properly and /or will not update."
    When you have two SWF installed the websites use the old one, not the new one. Don't ask me why, I often wonder that myself. That's why when you disabled the old one, Flash didn't work.
    Hope this solves the issue.
    Thanks,
    eidnolb

  • ClientAbortException problem on error page

    Hi
    I am trying to solve the mistery that has been bugging me for a while now.
    We have the same J2EE app deployed on 4 servers. The application is for content management.
    One server is for development, one for QA, and other 2 for production. All servers have same hardware and same software installed. All servers rund the same J2EE SDK with Sun's App Server 8.1PE...
    Now, the mistery....I only get the follwoing exception on the 2 production serversThe error page works fine on other servers and it is the same JSP page on all servers....I cannot figure out why I am getting this error and what is the error supposed to mean..
    [#|2004-09-02T08:23:56.703-0400|SEVERE|sun-appserver-pe8.0|javax.enterprise.system.container.web|_Th
    readID=11;|org.apache.catalina.core.StandardHostValve@ce41cc: Exception Processing ErrorPage[errorCode=404, location=/error404.jsp]
    ClientAbortException:  java.net.SocketException: Connection reset by peer: socket write error
            at org.apache.coyote.tomcat5.OutputBuffer.realWriteBytes(OutputBuffer.java:421)
            at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:444)
            at org.apache.coyote.tomcat5.OutputBuffer.doFlush(OutputBuffer.java:363)
            at org.apache.coyote.tomcat5.OutputBuffer.flush(OutputBuffer.java:345)
            at org.apache.coyote.tomcat5.CoyoteResponse.flushBuffer(CoyoteResponse.java:559)
            at org.apache.coyote.tomcat5.CoyoteResponseFacade$1.run(CoyoteResponseFacade.java:259)
            at java.security.AccessController.doPrivileged(Native Method)
            at org.apache.coyote.tomcat5.CoyoteResponseFacade.flushBuffer(CoyoteResponseFacade.java:254)
            at org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:362)
            at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:210)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:156)
            at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:180)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:154)
            at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:582)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:154)
            at com.sun.enterprise.webservice.EjbWebServiceValve.invoke(EjbWebServiceValve.java:134)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:154)
            at com.sun.enterprise.security.web.SingleSignOn.invoke(SingleSignOn.java:254)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:154)
            at com.sun.enterprise.web.VirtualServerValve.invoke(VirtualServerValve.java:209)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:154)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:569)
            at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:161)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:156)
            at com.sun.enterprise.web.VirtualServerMappingValve.invoke(VirtualServerMappingValve.java:16
    6)
            at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:154)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:569)
            at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:979)
            at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:211)
            at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:692)
            at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11P
    rotocol.java:647)
            at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:589)
            at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:691)
            at java.lang.Thread.run(Thread.java:534)
    |#]

    Hi. I am also same kind of problem. I ahve a simple JSP in my Struts 2 Application. Server used is weblogic. As soon as i click on the Calender Image. The Socket write erro is thrown. I a m not able to under stand as to why socket write error is happening, as inly a simple javascript function call happens on click of that image.
    JSP Cal code:
    value="<s:date name='remitFileSetup.effcvStartDt' format='MM/dd/yyyy'/>" size='10' maxlength='10'/><a id="Date1" href="#"><img onclick="javascript:callSelf('Date1','startdate','true','divMesReg1')" valign="bottom" src="<s:url value="/images/cal.gif"/>"
    method implementation:
    function call(cButton, cOutput, cSingle,divId) {
    var MA = [];
         //alert("HI 1");
         //to convert cSingle into boolean
         if(cSingle=='false')
         cSingle=false;
    else{
              cSingle=true;
    function closed(cal) {
    // here we'll write the output; this is only for example. You
    // will normally fill an input field or something with the dates.
    var el = document.getElementById(cOutput);
    // reset initial content.
    //el.innerHTML = "";
              if(cSingle==true) {
                   el.value="";
    // Reset the "MA", in case one triggers the calendar again.
    // CAREFUL! You don't want to do "MA = [];". We need to modify
    // the value of the current array, instead of creating a new one.
    // Calendar.setup is called only once! :-) So be careful.
    MA.length = 0;
    // walk the calendar's multiple dates selection hash
    for (var i in cal.multiple) {
    var d = cal.multiple;
    //alert("HI 2");
    // sometimes the date is not actually selected, that's why we need to check.
    if (d) {
    //this is to check that the newly selected date is not a repetition of of the date already
    // selected in the textbox
    var tempOlddate=trim(el.value);
    var flagTest="true";
    if(tempOlddate.indexOf(d.print("%m/%d/%Y"))==-1)
    var tmpoldDt=el.value;
         // OK, selected. Fill an input field. Or something. Just for example,
    // we will display all selected dates in the element having the id "output".
    var x=el.value;
    var y= x.substring(x.length-2,x.length);
    //alert(y);
    //alert("n"+y.indexOf("\n"));
    //alert("br"+y.indexOf("<br />"));
    if(trim(y)=="" )
         el.value +=d.print("%m/%d/%Y") + "<br />";
    else if(y.indexOf("\n")!= -1 )
         el.value +=d.print("%m/%d/%Y") + "<br />";
              else if(y.indexOf("/>")!=-1)
         el.value +=d.print("%m/%d/%Y") + "<br />";
              else{
         el.value +="<br />"+ d.print("%m/%d/%Y") + "<br />";
    // and push it in the "MA", in case one triggers the calendar again.
    MA[MA.length] = d;
         var vararray= new Array();
    var temp= el.value;
         vararray = temp.split("<br />");
         el.value="";
         for(i=0; i<vararray.length-1; i++) {
    el.value+=vararray[i];
    if(i < vararray.length) {
         el.value+="\n";
         if(cSingle==true) {
              if(vararray.length>2){
                   //alert('User cant select more than one date.');
                   document.getElementById(divId).style.display="inline";
                   el.value="";
         else {
              document.getElementById(divId).style.display="none";
    cal.hide();
    return true;
         //alert("HI 4");
    Calendar.setup({
    align : "BR",
    showOthers : true,
    multiple : MA, // pass the initial or computed array of multiple dates to be initially selected
    onClose : closed,
    button : cButton,
    singleMulti : cSingle
         //alert("HI 3");
    ERROR:
    org.apache.struts2.views.jsp.ComponentTagSupport.doStartTag(ComponentTagSupport.java:54)
         at jsp_servlet.__404._jsp__tag4(__404.java:270)
         at jsp_servlet.__404._jspService(__404.java:135)
         at weblogic.servlet.jsp.JspBase.service(JspBase.java:34)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:283)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)
         at weblogic.servlet.internal.RequestDispatcherImpl.invokeServlet(RequestDispatcherImpl.java:530)
         at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:266)
         at weblogic.servlet.internal.ServletResponseImpl.sendError(ServletResponseImpl.java:710)
         at weblogic.servlet.internal.ServletResponseImpl.sendError(ServletResponseImpl.java:559)
         at weblogic.servlet.FileServlet.findSource(FileServlet.java:265)
         at weblogic.servlet.FileServlet.doGetHeadPost(FileServlet.java:188)
         at weblogic.servlet.FileServlet.service(FileServlet.java:170)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:283)
         at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
         at org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:413)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
         at org.springframework.orm.jpa.support.OpenEntityManagerInViewFilter.doFilterInternal(OpenEntityManagerInViewFilter.java:111)
         at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:75)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
         at org.apache.struts2.dispatcher.ActionContextCleanUp.doFilter(ActionContextCleanUp.java:99)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
         at javawebparts.filter.AppAvailabilityFilter.doFilter(AppAvailabilityFilter.java:485)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
         at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3242)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
         at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2010)
         at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:1916)
         at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1366)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)

  • Custom 404 error page only works 75% of the time

    I have made custom HTTP error pages for my app and they work for Mozilla, Opera and Firefox but IE seems to have its own personal 404 error page.
    Anyone know how to make IE work and play well with others and display the custom 404 page like the other 3 browsers do? I did clear the IE cache, twice.
    The environment is Tomcat 5.0.19 (stand-alone, no IIS) running on Window Server 2003 Enterprise
    Thanks for your help!
    Will

    You got to love microsoft products huh. Microsoft has turned on its friendly error pages. Unfortunately, to fix this, you have to have your clients modified their browser settings. Inside the IE browser, do the following:
    1. From menu choose tools->internet options
    2. Choose the advanced tab
    3. Uncheck the checkbox that says "Show friendly HTTP error messages"
    That will do it for ya.

  • Direct  control to error page

    Hi everyone,
    I have a web application, in case if the link to a particular jsp is wrong then the server displays a page showing the message that page cud not be found and it also displays a link showing the server ip with the message that "please contact your system administratot".Say if I dont want that page to be displayed but an error page of my own.For a common eoor we usually have an entry in our web.xml but what should i do for such an error.I am using Tomcat.

    Hi,
    I understand you are trying to customize a standard page flow instead of A->B->C, you want to make it
    A->C,
    You have to extend the A's Controller and get the handle of the "Add Button" and transfer the page to 3rd page.
    Decompile the 2nd page controller and check what the standard code is doing for the event 'Find Button' click.
    You have to replicate the same.
    But this could give some error, since the third page might expect some parameters which was passed from 2nd page.
    You have to try and check.
    Thanks.
    With Regards,
    Kali.
    OSSI.

Maybe you are looking for

  • How many workbook can be broadcasted with 1 resgistered precalc instance

    Hi all, i did what you said now i have another question you have mentioned to register 10 instances of the precalculation server on 1 desktop machine, but SAP recommends to register 3 instances in the documentation from matthias nutt. Now the questio

  • End of Statement error

    I have the a query that keeps coming up with an error when I try to place in in a form as VBA. The following is the code: txtOperationID = "SELECT TOP 1 [idsOpSymbolID] & " " & Format([txtOperationSub#]+1,"0000") AS NewOpID " & _ "FROM tblOperations

  • How to get rid of ttys000 in terminal

    I got ttys000 in my terminal in front of my name  and sometimes terminal say restored

  • Backing Beans Object Oriented Design

    Hello, Are there any best practices for using Backing Beans? How to make managed beans thread-safe for concurrent requests, without compromising on efficiency/speed? 2. How to enforce the J2EE security with backing-beans? 3. How to decide the scope o

  • After a disk crash. I tunes does not see the file with my music in it.  How do I fix this?

    Windows 7 PC.  Disk crash.  Restored disk.  Reinstalled itunes.  I tunes does not see my music.  Music is in a folder called myipodmusic.  Has sub folders for artists, below artists has files for songs.  Any ideas??  Actually itunes sees my music tit