JSP mapping in Tomcat

I've a directory structure in Tomcat that looks like :
TOMCAT_HOME\webapps\Security\jsp\
Guys I need help on JSP mapping.
I'm running Tomcat and I want all the /Security/*.jsp requests in Browser goto above context.
i.e. http://localhost/Security/AJSP1.jsp
should go an invoke TOMCAT_HOME\webapps\Security\jsp\AJSP1.jsp
I donot want to manually map each JSP file in web.xml .
I just want any browser request with URL
http://localhost/Security/*.jsp
goto TOMCAT_HOME\webapps\Security\jsp\
Is there a way around.
Thanks in advance.
sam

Put it in the conf/server.xml file. Check Tomcaat documentation for proper location. Here is a small ex.
<Context path="/Security" docBase="<physical location>" debug="0" reloadable="true" crossContext="true" />

Similar Messages

  • JSP mapping with Tomcat 5.0.27

    With Jakarta-Tomcat 5.0.27 is it possible to put a JSP file in a sub-directory of a web application and be able to "servlet-mapping" it to only create one object? If so how do you write the web.xml entry? I only want to create one InitTest object, not two of them!
    If I place InitTest.jsp in the following directory structure:
    C:\tomcat\webapps\web-app\subDirectory\InitTest.jsp
    This web.xml entry does not work:
         <servlet>
              <servlet-name>InitTest</servlet-name>
              <jsp-file>/subDir/InitTest.jsp</jsp-file>
         </servlet>
         <servlet-mapping>
              <servlet-name>InitTest</servlet-name>
              <url-pattern>/InitTest.jsp</url-pattern>
         </servlet-mapping>When I use this link:
    http://localhost:8080/web-app/subDir/InitTest.jsp
    I get "jsp" as the servlet name
    and
    When I use this link:
    http://localhost:8080/web-app/servlet/InitTest
    I get "InitTest" as the servlet name
    How do I map InitTest.jsp correctly when it's placed in a sub-directory of the web application's directory?

    dear friend...y do you want to map your jsp page?? you can directly access your jsp from your location. You dont needd to map in the web.xml. You need to map only servlets not jsps
    regards
    shanu

  • Problem in running a jsp page on tomcat 5.0

    hi....
    i made a java class abc.java and then compiled it to get a java class file named abc.class in a package named pkg.
    Then i copied this package in the classes folder of the WEB-INF folder in tomcat 5.0.
    After that i created a jsp page in which i imported this class file. Now when i run the jsp page on tomcat 5.0 i get an error saying this:
    javax.servlet.ServletException: pkg/abc (Unsupported major.minor version 49.0)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:244)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    root cause
    java.lang.UnsupportedClassVersionError: pkg/abc (Unsupported major.minor version 49.0)
         java.lang.ClassLoader.defineClass0(Native Method)
         java.lang.ClassLoader.defineClass(ClassLoader.java:502)
         java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
         org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1634)
         org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:860)
         org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1307)
         org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1189)
         org.apache.jasper.compiler.Generator$GenerateVisitor.visit(Generator.java:1214)
         org.apache.jasper.compiler.Node$UseBean.accept(Node.java:1116)
         org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
         org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2213)
         org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2219)
         org.apache.jasper.compiler.Node$Root.accept(Node.java:456)
         org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
         org.apache.jasper.compiler.Generator.generate(Generator.java:3272)
         org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:244)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:495)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:476)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:464)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:511)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:295)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    Can anyone please tell me the solution to this problem?
    thanks

    This post:
    http://mail-archives.apache.org/mod_mbox/jakarta-tomcat-user/200408.mbox/%[email protected]ys.com%3E
    Leads me to believe that you're compiling and targeting a java version that your tomcat installation doesn't support. What version of the JDK are you using?
    Good Luck
    Lee

  • Jsp program on tomcat

    I am having trouble with a simple jsp program on tomcat. I have one Java bean class that the jsp cannot find. It is in the classes directory under WEB-INF. I have tried it with and without my web.xml file and I get the same error.
    org.apache.jasper.JasperEXception:  Unable to compile class for JSP:
    An error occurred at line: 5 in the jsp file: processFormData.jsp
    The import Inn cannot be resolved
    <%@page language="java"%>
    <%@page import="Inn"%>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitiional//EN />"
    <jsp:useBean id="inn" scope="request" class="Inn"/>
    <jsp:setProperty name="inn" property="*" />Julie

    Thanks. I'm not sure I understand why, but that was the problem.

  • Problem on reload a JSP file in Tomcat 3.3.1

    I have a problem about Tomcat 3.3.1
    I am developing a JSP application,
    but Tomcat not recompile the JSP file after i modify it.
    I need to "wait" the tomcat recompile it, so i can see the change.
    This make the development really difficult...
    Do I miss some important step on config Tomcat 3.3.1
    how to force it to detect a newer version JSP in every request ??
    Thanks

    I believe there is a way to configure Tomcat to do this, but I don't know what it is.
    Until someone can tell you the configuration steps, here is a workaround. Tomcat keeps the Java source and class files for your JSP code somewhere under its "work" directory. Find those files and delete them, which will force it to re-compile.

  • How to see JSP compilation errors - Tomcat 4.1.18- JDK 1.4

    Hi There,
    I'm kind of new to JSP world, so once in while I forget to put a ; or I put a variable name wrong (I usualy use Eclipse to do my coding in JAVA, but the existing plugins for JSP development are still in their early stages, so there's isn't any plugin that indicates errors on JSP before deploying them).
    When I try to see a JSP, if it has an error (compilation-time error), I get this message:
    <--->
    org.apache.jasper.JasperException: Unable to compile class for JSP
    An error occurred at line: -1 in the jsp file: null
    Generated servlet error:
    [javac] Compiling 1 source file
    <--->
    This doesn't help me a lot to fix the problem, I would like to, at least, see from what line the error came from.
    Help anyone?
    Thank You
    Pinho

    This kind of errors often come from syntax error in
    the jsp page.
    Tomcat is not very friendly with this kind of errors.
    A trick is to open the java file under the 'work'
    directory and checkIsn't there any way to show the error on a page, just like a run-time error?
    Maybe changing some log setting?

  • How to use debug my jdevloper devloped jsp applications using tomcat 4.0?

    hello,
    how to use debug my jdevloper devloped jsp applications using tomcat 4.0?
    how to run with using tomcat path with browser?
    can any one help?
    thanks
    pullareddy

    Hi Pullareddy,
    Charles' answer will work for Servlets in Tomcat, but debugging JSPs is a bit more complicated than debugging Servlets.
    Here's what you need to do:
    (I don't have Tomcat, so I don't know the details of Tomcat configuration files and I can't guarentee that Tomcat provides the flexibility so that you can configure it for debugging JSPs. Each application server is configured a bit differently. Hopefully you can adjust the following instructions to Tomcat.)
    1. You need to replace Tomcat's JSP engine with OJSP and you need to setup debugging parameters for OJSP.
    This is not specifically in the JDev documentation, but you may be able to apply the information found in the topic "Remote Debugging in OC4J".
    Here are some tips:
    A. You'll probably need to specify the following jars in some Tomcat config file: ojsp.jar, ojsputil.jar, xmlparserv2.jar, ojc.jar, and jdev-rt.jar.
    B. The OJSP class name is oracle.jsp.runtimev2.JspServlet.
    C. The debug parameters are:
    debug_mode = true
    developer_mode = true
    encode_to_java = true
    emit_debuginfo = true
    jspjavacompiler = oracle.jdevimpl.jsp.JspOjcCompiler
    2. You need to make Tomcat start the Java command with debugging options. (This is what Charles was talking about. One of the debug options is -XXdebug). This is in the JDev documentation in the topic "Starting a Java Process in Debug Mode". Please read that documentation help topic.
    3. You need to delete any old .java or .class files which were created in the past for your JSP. If you leave old .java or .class files around, then the debugger may not be able to stop at breakpoints in your JSPs. So, be sure to clean up old files.
    4. Set your project settings for remote debugging. This is on the Debugger - Remote panel in the Project Settings dialog box. You probably want either Attach to OJVM or Attach to JPDA. Which radio button you choose depends on what command line options you specified in step 2.
    -Liz

  • How to call EJB deployed on websphere from JSP running on Tomcat?

    I am trying to establish communication between two app servers. I have a sample EJB deployed on Websphere and wish to call its business methods from a JSP page which is running on Apache Tomcat server. (ie) Tomcat is client to websphere. Is it possible to do? If so, what are the client Jar files of websphere that I should make available to JSP page on Tomcat? Do I need to set any Jars in Tomcat environment variables? Lood forward for your immediate help. Thanks in advance

    Please see the thread
    http://forum.java.sun.com/thread.jspa?threadID=514536.
    Hope that helps..

  • Use of xml syntax for jsp's in tomcat 4.0.1?

    hi,
    i am playing around with jsp's on tomcat 4.0.1. when i use xml tags in my jsp's, it appears that tomcat ignores them, eg:
    <jsp:scriptlet>
    code
    </jsp:scriptlet>
    Tomcat does not seem to be running the code - it just prints it out on the screen.
    If I use
    <%
    code
    %>
    it works fine. This also seems to happen for other XML tags, such as <jsp:directive.page>
    Does Tomcat support JSP documents (ie: where all jsp tags are XML?). If it's Servlet 2.3 compliant, I figured it would have to.
    Perhaps I am just doing something foolish?
    Guidance is appreciated.
    Thanks,
    Steve

    Not anything definitive, although a colleague told me that apparenlty not all tags were supported by Tomcat. I suppose there are a few options such as looking at the Jasper source code.
    Steve

  • View JSP Examples in Tomcat 4

    Hello everyone,
    I will really appreciate your advise on this problem.
    I am not able to run the JSP examples in Tomcat 4. I can see that the document sais:
    These examples will only work when these pages are being served by the ServletRunner. They will not work if you are viewing these pages via a "file://..." URL.
    But I don't know what does that mean. What should I do? How can I view these examples?
    Thank you very much for any advise and for your time.
    Martin

    >
    Normally JSP pages will be executed at server side
    e before serving
    the output to client. But you can see the same file
    using any editor
    or using windows explorer.i.e you are directly viewing
    the jsp page.
    here you are using file protocol. But when you access
    the same page
    using any browser by specifying it's URL for ex:
    http://localhost:8080/myjsp.jsp
    you are using http as protocol to get the required
    page/file.
    Gayam.Srinivasa ReddyHello ,
    My problem is that when I start Tomcat and type in my browser:
    http://localhost:8080/examples/jsp/index.html
    I see the JSP examples. But when I try to click on one of them,
    I get an error like this:
    http://localhost:8080/examples/jsp/num/numguess.jsp
    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
    javax.servlet.ServletException: Servlet.init() for servlet jsp threw exception
         at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:935)
         at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:653)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214).......
    ....and so on...........
    root cause
    java.lang.NoSuchMethodError: javax.servlet.ServletContext.getResourcePaths(Ljava/lang/String;)Ljava/util/Set;
         at org.apache.jasper.compiler.TldLocationsCache.processJars(TldLocationsCache.java:202)
         at org.apache.jasper.compiler.TldLocationsCache.(TldLocationsCache.java:139)
         at org.apache.jasper.EmbededServletOptions.(EmbededServletOptions.java:345)
         at org.apache.jasper.servlet.JspServlet.init(JspServlet.java:266)
         at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:916)
    ....................and so on
    Please give me a hint of how to fix this problem.
    Thank you very much for your time and advise!
    Martin
         

  • Cannot compile JSP pages in Tomcat 5.0.28

    Hi,
    I'm new to Tomcat and this has been bothering me for days now.
    I have (seemingly) correctly installed Tomcat v5.0.28 and am currently in the process of testing my environment with simple html/jsp pages.
    My server starts up fine with no error messages.
    Testing the server I can access the .html file fine, however I get a HTTP 404 error for the .jsp: The requested resource (/hello/hello.jsp) is not availableI have done the following since installation:
    1. Installed Tomcat to C:\Program Files\jakarta-tomcat-5.0.282. Set the environment variable JAVA_HOME to the value C:\Program Files\Java\jdk1.5.0 (base directory of my java installation)
    3. Even added ;C:\Program Files\Java\jdk1.5.0\bin to the environment variable Path (just in case, for javac)
    4. Enabled the invoker sevlet by uncommenting:
        <servlet>
            <servlet-name>invoker</servlet-name>
            <servlet-class>
              org.apache.catalina.servlets.InvokerServlet
            </servlet-class>
        </servlet>and
        <servlet-mapping>
            <servlet-name>invoker</servlet-name>
            <url-pattern>/servlet/*</url-pattern>
        </servlet-mapping>in conf/web.xml
    5. Added an access log valve to locahost
    6. Set ant fork compiles to seperate JVMs:
        <servlet>
            <servlet-name>jsp</servlet-name>
            <servlet-class>org.apache.jasper.servlet.JspServlet</servlet-class>
            <init-param>
                <param-name>fork</param-name>
                <param-value>true</param-value>
            </init-param>
            <init-param>
                <param-name>xpoweredBy</param-name>
                <param-value>false</param-value>
            </init-param>
            <load-on-startup>3</load-on-startup>
        </servlet>6. Installed the .html and .jsp pages to folder %CATALINA_HOME%/webapps/ROOT/helloNow when I bin/startup.bat Tomcat starts without anu error messges. In a browser I can now access http://localhost:8080 and http://localhost:8080/hello/hello.html but not http://localhost:8080/hello/hello.jspHere are my logfiles (in debug mode) for performing the above actions and then shutting down:
    catalina_log.txt
    2006-04-29 18:29:02 EngineConfig: EngineConfig: Processing START
    2006-04-29 18:29:24 EngineConfig: EngineConfig: Processing STOPlocalhost_log.txt
    2006-04-29 18:29:01 StandardContext[/balancer]org.apache.webapp.balancer.BalancerFilter: init(): ruleChain: [org.apache.webapp.balancer.RuleChain: [org.apache.webapp.balancer.rules.URLStringMatchRule: Target string: News / Redirect URL: http://www.cnn.com], [org.apache.webapp.balancer.rules.RequestParameterRule: Target param name: paramName / Target param value: paramValue / Redirect URL: http://www.yahoo.com], [org.apache.webapp.balancer.rules.AcceptEverythingRule: Redirect URL: http://jakarta.apache.org]]
    2006-04-29 18:29:01 StandardContext[/jsp-examples]ContextListener: contextInitialized()
    2006-04-29 18:29:01 StandardContext[/jsp-examples]SessionListener: contextInitialized()
    2006-04-29 18:29:02 StandardContext[/servlets-examples]ContextListener: contextInitialized()
    2006-04-29 18:29:02 StandardContext[/servlets-examples]SessionListener: contextInitialized()
    2006-04-29 18:29:24 StandardContext[/servlets-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@14eaec9')
    2006-04-29 18:29:24 StandardContext[/servlets-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@b533b8')
    2006-04-29 18:29:24 StandardContext[/servlets-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@569c60')
    2006-04-29 18:29:24 StandardContext[/servlets-examples]SessionListener: contextDestroyed()
    2006-04-29 18:29:24 StandardContext[/servlets-examples]ContextListener: contextDestroyed()
    2006-04-29 18:29:24 StandardContext[/jsp-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@d67067')
    2006-04-29 18:29:24 StandardContext[/jsp-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@6db724')
    2006-04-29 18:29:24 StandardContext[/jsp-examples]ContextListener: attributeReplaced('org.apache.catalina.WELCOME_FILES', '[Ljava.lang.String;@112da40')
    2006-04-29 18:29:24 StandardContext[/jsp-examples]SessionListener: contextDestroyed()
    2006-04-29 18:29:24 StandardContext[/jsp-examples]ContextListener: contextDestroyed()localhost_access_log.txt
    127.0.0.1 - - [29/Apr/2006:18:29:13 +0930] "GET /hello/hello.html HTTP/1.1" 304 -
    127.0.0.1 - - [29/Apr/2006:18:29:19 +0930] "GET /hello/hello.jsp HTTP/1.1" 404 1000Also, my sourced test .html and .jsp files:
    hello.html
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
    <!--
    Simple HTML file to test server setup and configuration.
    Taken from Core Servlets and JavaServer Pages 2nd Edition
    from Prentice Hall and Sun Microsystems Press,
    http://www.coreservlets.com/.
    (C) 2003 Marty Hall; may be freely used or adapted.
    -->
    <HTML>
    <HEAD><TITLE>HTML Test</TITLE></HEAD>
    <BODY BGCOLOR="#FDF5E6">
    <H1>HTML Test</H1>
    Hello.
    </BODY></HTML>hello.jsp
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
    <!--
    Simple JSP file to test server setup and configuration.
    Taken from Core Servlets and JavaServer Pages 2nd Edition
    from Prentice Hall and Sun Microsystems Press,
    http://www.coreservlets.com/.
    (C) 2003 Marty Hall; may be freely used or adapted.
    -->
    <HTML>
    <HEAD><TITLE>JSP Test</TITLE></HEAD>
    <BODY BGCOLOR="#FDF5E6">
    <H1>JSP Test</H1>
    Time: <%= new java.util.Date() %>
    </BODY></HTML>I am getting so frustrated I feel like I have tried everything...

    Thanks for your feedback, I tried all suggestions but still no luck.
    One thing I didn't mention previously was I have also tried the following (note: I have omitted the prefix "%CATALINA_HOME%/webapps"
    to all directory references below):
    1. installed my .jsp directly into /ROOT
    2. installed my .jsp into subdirectory /ROOT/hello
    3. installed my .jsp into /root_copy (identified as a running application by Tomcat manager)
    I think there must a problem in my deployment because the JSP examples (http://localhost:8080/jsp-examples/) compile fine...
    This indicates that JAVA_HOME is set correctly.
    Since my first post I tried installing tomcat from a windows installer into c:\apache\tomcat5.0.28\ and set logging to debug.
    Here's a small dump of 5 logs in localhost_log.2006-05-01.txt:
    2006-05-01 20:08:31 StandardContext[/balancer]org.apache.webapp.balancer.BalancerFilter]...
    2006-05-01 20:08:32 StandardContext[/jsp-examples]ContextListener: contextInitialized()
    2006-05-01 20:08:32 StandardContext[/jsp-examples]SessionListener: contextInitialized()
    2006-05-01 20:08:32 StandardContext[/servlets-examples]ContextListener: contextInitialized()
    2006-05-01 20:08:32 StandardContext[/servlets-examples]SessionListener: contextInitialized()Note there was no initialization of the context root_copy, but I'm unsure if there's any relevance here or not.

  • Virtual directory mapping in tomcat

    How can I virtually map directories in tomcat ?
    Example I want to access .../images directory from jsp page by /images.
    it is possible in weblogic but how can i implement it into tomcat .
    If any body can help me regarding this , It would help me .
    Thanks in advance.

    One way could be to do it with the urlrewrite filter: http://tuckey.org/urlrewrite/

  • JSP: work with TomCat 5.5.9 and NOT work with TomCat 6.0.16

    Hi all,
    I'm Antony and I have a problem with a .JSP page of my server.
    In my server there are 2 users: "u1" and "u2"; there are 2 TomCat, version 5.5.9 and version 6.0.16. There is Apache WebServer version 2. The 2 TomCat servers have the same configuration files: server.xml and web.xml (in the dir /conf of the main server's root). They not work simultaneously.
    When the user "root" launch the TomCat 5.5.9 all work fine: the server will show correctly the JSP pages of "u1" and the pages of "u2".
    When the user "root" launch the TomCat 6.0.16 the JSP pages of "u1" work fine but the JSP pages of "u2" not work: it seems that there are problems with the path where the server want to search the pages of u2.
    In the server.xml there is this code (for the handle of u2's site):
    <Host name="u2site.com" appBase="/home/u2/public_html/">
      <Alias>www.u2site.com</Alias>
      <Context path="" reloadable="false" docBase="/home/u2/public_html/" debug="0"/>
              <Context path="/manager" debug="0" privileged="true"
                  docBase="/usr/local/jakarta/tomcat/server/webapps/manager">
              </Context>
    </Host>and this code (for the u1's site)
    <Host name="u1site.com" appBase="/home/u1/public_html/">
      <Context path="" reloadable="false" docBase="/home/u1/public_html" debug="1"/>
              <Context path="/manager" debug="0" privileged="true"
                  docBase="/usr/local/jakarta/tomcat/server/webapps/manager">
              </Context>
    </Host>The problems with the JSP pages of u2 are one of the following:
    org.apache.jasper.JasperException: /login2.jsp(4,0) The value for the useBean class attribute com.u2.beans.access.Autenticator is invalid.and this one that appear with the pages that have the inclusion of another JSP page
    /u2page.jsp(3,0) File "/../support/_formatting.jsp" not foundI think that the TomCat know how to find the page that the browser request to Apache WebServer (and that the webserver request to Tomcat by the connector) 'cause for pages that haven't inclusion or call to method in packages all work fine...but the TomCat have problems to locate the pages included or the method located in a JAR (the jars are located in WEB-INF/lib/ of the u2's site).
    How I can resolve this problem with TomCat 6.0.16? I repeat that with TomCat 5.5.9 all work fine...same configuration!
    Any ideas?
    Thank you very much,
    Antony.

    Hi stevejluke, 'cause in the page "/supporto/_formatting.jsp" there are only the definition of some variables it's normal that the output at the browser it's a blank page.
    The problem it's that Tomcat 6.0.16 cannot know how "navigate" the pages beginning from one...it know where is the "x.jsp" page requested directly by Apache WebServer, where is "y.jsp" request directly by Apache, where is "z.jsp" requested directly by Apache but if "x.jsp" request, includes, "y.jsp" Tomcat cannot know where "y.jsp" is located. There is some file where I can "say" this to Tomcat?
    The page "/mostre/elenco_mostre.jsp" includes directly the "/supporto/_formatting.jsp".
    Another thing: in /mostre/elenco_mostre.jsp there is an inclusion directive for /supporto/_formatting.jsp that is so:
    <%@ include file="../supporto/_formatting.jsp"%>you can see that the included file is "../supporto/_formatting.jsp" and NOT "/../supporto/_formatting.jsp"...the "/" at the begin of the path is included by Tomcat!
    In the catalina.out there are this lines, when the page is called:
    Jul 6, 2008 3:15:00 AM org.apache.catalina.core.StandardWrapperValve invoke
    SEVERE: Servlet.service() for servlet jsp threw exception
    org.apache.jasper.JasperException: /elenco_mostre.jsp(3,0) File "/../supporto/_formatting.jsp" not found
      In catalina.out before server start there are this lines:
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '1' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '0' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '1' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '0' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '1' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '0' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '1' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '0' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '1' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '0' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '1' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '0' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '0' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
    WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'debug' to '0' did not find a matching property.
    Jul 6, 2008 1:43:49 AM org.apache.catalina.startup.Catalina load
    INFO: Initialization processed in 358 ms
    Jul 6, 2008 1:43:49 AM org.apache.catalina.core.StandardService start
    INFO: Starting service Catalina
    Jul 6, 2008 1:43:49 AM org.apache.catalina.core.StandardEngine start
    INFO: Starting Servlet Engine: Apache Tomcat/6.0.16
    Jul 6, 2008 1:43:52 AM org.apache.jk.server.JkMain start
    INFO: Jk running ID=0 time=0/23  config=null
    Jul 6, 2008 1:43:52 AM org.apache.catalina.connector.MapperListener registerEngine
    WARNING: Unknown default host: localhost
    Jul 6, 2008 1:43:52 AM org.apache.catalina.startup.Catalina start
    INFO: Server startup in 2512 msThe file "web.xml" is located in "$Tomcat_home/conf" and it's:
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <web-app xmlns="http://java.sun.com/xml/ns/j2ee"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
        http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4">
      <servlet>
        <servlet-name>jsp</servlet-name>
        <servlet-class>org.apache.jasper.servlet.JspServlet</servlet-class>
        <init-param>
          <param-name>fork</param-name>
          <param-value>false</param-value>
        </init-param>
        <init-param>
          <param-name>xpoweredBy</param-name>
          <param-value>false</param-value>
        </init-param>
        <load-on-startup>3</load-on-startup>
      </servlet>
      <servlet-mapping>
        <servlet-name>jsp</servlet-name>
        <url-pattern>*.jsp</url-pattern>
      </servlet-mapping>
      <servlet-mapping>
        <servlet-name>jsp</servlet-name>
        <url-pattern>*.jspx</url-pattern>
      </servlet-mapping>
      <session-config>
        <session-timeout>30</session-timeout>
      </session-config>
      <welcome-file-list>
        <welcome-file>index.html</welcome-file>
        <welcome-file>index.jsp</welcome-file>
      </welcome-file-list>
    </web-app>there are not web.xml file in /WEB-INF/ of the web application.
    Maybe the problem it's that Tomcat want the conf file in "Server/Service/Engine/Host/Context" ? I must move the block HOST of the server.xml file in this path?
    Good Sunday and thank you!
    Antony.

  • Calling a class in JSP page using Tomcat 5.5

    Hi,
    I want to call a java class in a JSP page but getting error.
    I am trying to deploy JSP through a WAR file so for that I have created folder structure as per requirement and in WEB-INF folder, I kept web.xml file.
    What entry exactly I have to make in web.xml file as I am using Tomcat 5.5 webserver. When the same code I put in JSP then it works.
    my web.xml entry is
    <servlet>
    <servlet-name>TBS</servlet-name>
    <servlet-class>pack1.GetData</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>TBS</servlet-name>
    <url-pattern>/JSP/TBS_main</url-pattern>
    </servlet-mapping>
    Do I need to change in it or we have to make some more entries in different XML files.
    Please help me to resolve this issue.
    Thanks
    Mukesh

    you dont have to specify the class file in the web.xml just import it on your jsp then instatiate the class on the scriplet and you can call the methods on it.

  • Quick question about url/jsp mapping

    Could anyone clarify whether the following mapping in the web.xml file is possible?
    I want to access the file webapps\examples\gate\login.jsp by going to the page http://192.168.2.143:8080/work/login.jsp instead of http://192.168.2.143:8080/examples/gate/login.jsp
    Currently I can map it fine to http://192.168.2.143:8080/examples/work/login.jsp,
    which is an existing folder, but when I try and get it above the examples folder, it gives me the 404 error.
        <servlet>
            <servlet-name>Login</servlet-name>
            <jsp-file>/gate/login.jsp</jsp-file>
        </servlet>
        <servlet-mapping>
            <servlet-name>Login</servlet-name>
            <url-pattern>/../work/login.jsp</url-pattern>
        </servlet-mapping>

    Using only work/login.jsp will cause an error, and the tomcat server to crash, if I use the pattern
    <url-pattern>/work/login.jsp</url-pattern>, I just map the URL http://192.168.2.143:8080/examples/work/login.jsp instead of
    http://192.168.2.143:8080/examples/gate/login.jsp
    My entire webaps structure is rather long, and contains code other than my own, so I'd rather not post it, I just need to figure out if it is possible to map the jsp page to a path above the file. (do you think I need to do it in another web.xml?)

Maybe you are looking for

  • Can't export downloaded album

    I purchased an e-album on amazon.com. It appeared in my I-tunes library, where I'm able to listen to it and to burn a CD. However, I can't export it to my Rhapsody software so that I can download it to my Sansa. When I try to "Import files" using Rha

  • Downgrading IE11 in Windows 8

    Dear Team, Can anyone help me in getting some information about downgrading the IEv11 in Windows 8.1. In the W 8 OS the IE 11 comes as default, some of our ERP applications are not compatible with IE11 and this causes trouble. Help is highly apprecia

  • Infocube Compression

    Hi All, Presently we have a problem with Non cumulative infocube comression. It is like: Presently Non Cumulative infocube contains 2 years of data and we are extracting data from two datasources (2LIS_03_BX AND 2LIS_03_BF) since 2years it has not be

  • N/A in DataFields

    Hi all, When I map a domain class to a datafield, the field will show N/A when the domain class has a NULL value. I want it to show something else, like 'Empty' or 'Not filled yet' or nothing. How do I do that? Overriding 'FillString' will let me for

  • Anyone using facelets with ADF Faces and myfaces implementation?

    There is a Howto document for using facelets with ADF Faces, but it assumes you're using Sun's RI. I'd like to use the Apache myfaces implementation of JSF with ADF and facelets, but I keep getting a NoSuchElementException thrown when the pages are a