My system is Linux Redhat9 with Tomcat 5.0.16
 
I can successfully install my tomcat application.
When I enter the URL to visit my application the contents of the
"index.html" file are successfully displayed.
 
However, when I click on a "Submit" button from the form displayed
on the "index.html" that is when the problem occurs. Note that
the submit button is part of the FORM which is started as follows :
 
    <FORM method=post action="">
 
The following is the 1st part of the error message displayed in my
browser window :
 
===============================================
 
HTTP Status 500 -
 
Type  Exception Report
 
message
 
description  The server encountered an internal error () that
             prevented it from fulfilling this request
 
exception
 
org.apache.jasper.JasperException: Unable to compile class for JSP
 
An error occurred at line: 8 in the jsp file: /logon.jsp
 
Generated servlet error:
    [javac] Compiling 1 source file
   
$TOMCAT_HOME/work/Catalina/localhost/tomcat4/org/apache/jsp/logon_jsp.java:41:
              cannot resolve symbol
symbol    : class Jdbc2jsp
location  : class org.apache.jsp.logon_jsp
      Jdbcjsp2 foobar = null;
 
=================================================
 
Here is the contents of my "logon.jsp" file :
 
     1 <%@ page language="java" contentType="text/html" %>
     2 <%-- This JSP is to test my own personal Bean/class. --%>
     3 <html>
     4 <head>
     5 <title>Logon</title>
     6 </head>
     7 <body>
     8 <jsp:useBean id="foobar" scope="session" class="Jdbc2jsp" />
     9 <jsp:setProperty name="foobar" property="*" />
    10 
    11 <%-- First call the method that generates the data --%>
    12 <%
    13  foobar.display_user_table_contents();
    14 %>
    15 
    16 <%-- Now call the method that retrieves the generated data --%>
    17 <%= foobar.getHtmldata() %>
    18 
    19 </body>
    20 </html>
 
=================================================
 
The above JSP file was the same JSP file I used with Tomcat 4.?
under Windows a few years ago. Was it incorrect of me to assume
that the syntax would still be appropriate for Tomcat 5.0.16 ??
 
In my "src" directory for my Tomcat application there is a Java source
file named "Jdbc2jsp.java". This file has a "public class" named
"Jdbc2jsp".
 
So, the big question is what have I done wrong in terms of my JSP and
Java class file?? Am I possibly missing something in one of the
".xml" files ??
 
*************************
 
Barry Kimelman
Winnipeg, Manitoba, Canada
email :  [EMAIL PROTECTED] , [EMAIL PROTECTED]

Reply via email to