紧急~~JSP问题~~
请问下面这种错误应该怎样解决?
谢谢~~~
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 5 in the jsp file: /chapter06/book/index.jsp
Generated servlet error:
[javac] Compiling 1 source file
C:\Program Files\Apache Software Foundation\Tomcat 5.0\work\Catalina\localhost\TestJSP\org\apache\jsp\chapter06\book\index_jsp.java:7: ??? org.pan.web.book ???
import org.pan.web.book.bookclass;
^
C:\Program Files\Apache Software Foundation\Tomcat 5.0\work\Catalina\localhost\TestJSP\org\apache\jsp\chapter06\book\index_jsp.java:48: ??? org.pan.web ???
org.pan.web.bookclasslist classlist = null;
^
An error occurred at line: 5 in the jsp file: /chapter06/book/index.jsp
Generated servlet error:
C:\Program Files\Apache Software Foundation\Tomcat 5.0\work\Catalina\localhost\TestJSP\org\apache\jsp\chapter06\book\index_jsp.java:50: ??? org.pan.web ???
classlist = (org.pan.web.bookclasslist) _jspx_page_context.getAttribute( "classlist ", PageContext.PAGE_SCOPE);
^
An error occurred at line: 5 in the jsp file: /chapter06/book/index.jsp
Generated servlet error:
C:\Program Files\Apache Software Foundation\Tomcat 5.0\work\Catalina\localhost\TestJSP\org\apache\jsp\chapter06\book\index_jsp.java:52: ??? org.pan.web ???
classlist = new org.pan.web.bookclasslist();
^
An error occurred at line: 43 in the jsp file: /chapter06/book/index.jsp
Generated servlet error:
C:\Program Files\Apache Software Foundation\Tomcat 5.0\work\Catalina\localhost\TestJSP\org\apache\jsp\chapter06\book\index_jsp.java:99: ?????
??? ? bookclass
??? ? org.apache.jsp.chapter06.book.index_jsp
bookclass bc = (bookclass) classlist.getClasslist().elementAt(i);
^
An error occurred at line: 43 in the jsp file: /chapter06/book/index.jsp
Generated servlet error:
C:\Program Files\Apache Software Foundation\Tomcat 5.0\work\Catalina\localhost\TestJSP\org\apache\jsp\chapter06\book\index_jsp.java:99: ?????
??? ? bookclass
??? ? org.apache.jsp.chapter06.book.index_jsp
bookclass bc = (bookclass) classlist.getClasslist().elementAt(i);
^
???C:\Program Files\Apache Software Foundation\Tomcat 5.0\work\Catalina\localhost\TestJSP\org\apache\jsp\chapter06\book\index_jsp.java ?????????? API?
?????????????? -Xlint:deprecation ?????
6 ??
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:127)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:351)
org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:415)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:458)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:553)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:291)
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)
[解决办法]
你的JSP页面有错误!
在/chapter06/book/index.jsp
你去查一下,把错误改过来应该就行了
[解决办法]
第五行有错误
[解决办法]
<%@ page import= "org.pan.web.book.bookclass " %>
引用的类和
<jsp:useBean id= "classlist " scope= "page " class= "org.pan.web.bookclasslist " />
引用的类好象不一样哦
[解决办法]
你确定你的类名org.pan.web.book.bookclass,org.pan.web.bookclasslist,它们的地址都有效吗?
我的异常网推荐解决方案:org.apache.jasper.JasperException: Unable to compile class,http://www.myexception.cn/j2ee/2308.html