This code actually works for me.
getClass().getResourceAsStream(Configuration.xml);
I did dump the Configuration.xml file into the same directory where this
code exists and jar'ed them all up.
com/blort/packagename/Configuration.class
com/blort/packagename/Configuration.xml
You can
So it executed the Servlet Login2 as evidence in the stacktrace
root cause
java.lang.NoClassDefFoundError
at Login2.doGet(Login2.java:51)
at
javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
... and it got all the way to line 51. It looks like there
Had a similar problem. This code seems to work in a servlet (more comment
after):
--
PrintWriter out = null;
ServletContext servletContext = getServletContext();
try
{
out = response.getWriter();
}
catch ( IOException