same question here!
I put my Bean under TOMCAT\webapps\ROOT\web-inf\classes\MyPackage dir
and my jsp under TOMCAT\webapps\ROOT\
there is no error message
, but no result either.
in my
servlet I add my Bean to the ServletContext,using:
records = new Records();
...
getServletContext().setAttribute("records",records);
and in my JSP I access bean using:
<jsp:useBean id="records" class="MyPackage.Records" scope="application" />
</jsp:useBean>
<%
System.out.println("here Show the records");
Vector v = records.getRecords();
int p = 0;
while(p < v.size()){
out.println(v.elementAt(p));
System.out.println(v.elementAt(p).toString());
p++;
}
%>
Servlet is in the same package as Beans'. I made no modification with any file to configure
Tomcat.
Why I get no result?Could anybody tell what is going wrong?