java - JSP Subdirectory problem -- Unable to compile the jsp -
i have created website , hosted on windows , tomcat 6 .
the application not detect class files in web-inf->classes folder when access jsp file subdirectory.
i created jsp file access class file. jsp working fine when access root folder. if put same jsp file in subdirectory, throwing errors saying
http status 500 -
type exception report
message
description server encountered internal error () prevented fulfilling request.
exception
org.apache.jasper.jasperexception: /test.jsp(8,0) value usebean class attribute utils.logwriter invalid. org.apache.jasper.compiler.defaulterrorhandler.jsperror(defaulterrorhandler.java:40) org.apache.jasper.compiler.errordispatcher.dispatch(errordispatcher.java:407) org.apache.jasper.compiler.errordispatcher.jsperror(errordispatcher.java:148) org.apache.jasper.compiler.generator$generatevisitor.visit(generator.java:1229) org.apache.jasper.compiler.node$usebean.accept(node.java:1178) org.apache.jasper.compiler.node$nodes.visit(node.java:2361) org.apache.jasper.compiler.node$visitor.visitbody(node.java:2411) org.apache.jasper.compiler.node$visitor.visit(node.java:2417) org.apache.jasper.compiler.node$root.accept(node.java:495) org.apache.jasper.compiler.node$nodes.visit(node.java:2361) org.apache.jasper.compiler.generator.generate(generator.java:3440) org.apache.jasper.compiler.compiler.generatejava(compiler.java:231) org.apache.jasper.compiler.compiler.compile(compiler.java:347) org.apache.jasper.compiler.compiler.compile(compiler.java:327) org.apache.jasper.compiler.compiler.compile(compiler.java:314) org.apache.jasper.jspcompilationcontext.compile(jspcompilationcontext.java:592) org.apache.jasper.servlet.jspservletwrapper.service(jspservletwrapper.java:317) org.apache.jasper.servlet.jspservlet.servicejspfile(jspservlet.java:313) org.apache.jasper.servlet.jspservlet.service(jspservlet.java:260) javax.servlet.http.httpservlet.service(httpservlet.java:717)
from logs info
at org.apache.catalina.core.applicationfilterchain.internaldofilter(applicationfilterchain.java:290) @ org.apache.catalina.core.applicationfilterchain.dofilter(applicationfilterchain.java:206) @ org.apache.catalina.core.standardwrappervalve.invoke(standardwrappervalve.java:233) @ org.apache.catalina.core.standardcontextvalve.invoke(standardcontextvalve.java:191) @ org.apache.catalina.core.standardhostvalve.invoke(standardhostvalve.java:127) @ org.apache.catalina.valves.errorreportvalve.invoke(errorreportvalve.java:102) @ org.apache.catalina.core.standardenginevalve.invoke(standardenginevalve.java:109) @ org.apache.catalina.connector.coyoteadapter.service(coyoteadapter.java:298) @ org.apache.coyote.http11.http11aprprocessor.process(http11aprprocessor.java:861) @ org.apache.coyote.http11.http11aprprotocol$http11connectionhandler.process(http11aprprotocol.java:579) @ org.apache.tomcat.util.net.aprendpoint$worker.run(aprendpoint.java:1584) @ java.lang.thread.run(unknown source)
example:
test.jsp not working in www.gamestest.com\community work www.gamestest.com
code of test.jsp
<!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd"> <%@ page import="java.util.vector,utils.logwriter"%> <jsp:usebean id="logger" class="utils.logwriter" /> <html xmlns="http://www.w3.org/1999/xhtml"> <body> <div id="topmenu"> <%@ include file="/../include/menu.jsp"%> </div> </body> </html>
thanks alex
although don't have answer why not working when placed in sub directory, if working fine in root directory, in line , why don't try .
Comments
Post a Comment