• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

JSP Error when Struts simple login example

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All
I am trying to execute the example mentioned in the following :
http://www.javaranch.com/newsletter/Mar2002/struts.html
However I am using
Tomcat 5.0.18
Struts 1.1
The example mentioned in the above link however had some problems like the struts.tld does not exist anymore in the Struts 1.1 distribution, which the LoginView.jsp and MainMenu.jsp were using.So I removed the line that refered to struts.tld in the beginning of the jsp files.
Also it was referencing some of the classes which were not there in classpath.
I included following files in the struts/WEB-INF/lib directory of the development folder.
1.commons-logging.jar
2.jsp-api.jar
3.servlet-api.jar
struts.jar was placed as per the instructions in the link.
I am a new programmer in struts.Also I have learnt how to write a JSP recently.
I am trying out the example mentioned for the Struts beginners.But it always gives the following exception :
javax.servlet.ServletException
org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:867)
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:800)
org.apache.jsp.jsp.LoginView_jsp._jspService(LoginView_jsp.java:103)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:133)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:311)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)

root cause
java.lang.NoClassDefFoundError
java.lang.Class.forName0(Native Method)
java.lang.Class.forName(Class.java:140)
org.apache.jsp.jsp.LoginView_jsp.class$(LoginView_jsp.java:114)
org.apache.jsp.jsp.LoginView_jsp._jspx_meth_html_errors_0(LoginView_jsp.java:114)
org.apache.jsp.jsp.LoginView_jsp._jspService(LoginView_jsp.java:89)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:133)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:311)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
Please Help,I have been struggling with for long now.
 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Moving to the Struts forum.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic