`
koudailidexiaolong
  • 浏览: 96197 次
  • 性别: Icon_minigender_1
  • 来自: 西安
社区版块
存档分类
最新评论

严重: Servlet.service() for servlet DoIndex threw exception

 
阅读更多

在用jstl做jsp的时候报这个错误

严重: Servlet.service() for servlet DoIndex threw exception
org.apache.jasper.JasperException: <h3>Validation error messages from TagLibraryValidator for c in /index.jsp</h3><p>74: Empty var attribute in "j:forEach" tag.</p>
at org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:51)
at org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409)
at org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:74)
at org.apache.jasper.compiler.Validator.validateXmlView(Validator.java:1823)
at org.apache.jasper.compiler.Validator.validateExDirectives(Validator.java:1769)
at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:198)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:354)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:334)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:321)
at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:592)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:328)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:646)
at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:436)
at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374)
at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302)
at com.dragon.servlet.DoIndex.doPost(DoIndex.java:131)
at com.dragon.servlet.DoIndex.doGet(DoIndex.java:66)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:859)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:602)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Thread.java:619)
<wbr>找了半天不知道为什么只知道标签用的有问题</wbr>

这是页面中的代码

<%--显示所有的子类菜单 --%>
<j:forEach var="categoryInfo" items="${requestScope.categoryInfoList }" varStatus="status">
<%--判断是否为第一个 --%>
<j:if test="${status==0}">
<li class="first"><a href="#">${categoryInfo.categoryName }</a></li>
</j:if>
</j:forEach>

开始还以为什么写错了可是仔细的检查了一席,没错 发现只要把判断条件去掉就好了加上就报错

最后发现原来忘了在status后点index属性

改成status.index就好了

哎!一时铸成千古恨!恨死自己了把这个给忘了 希望对和我犯一样错误的人有所帮助!

分享到:
评论

相关推荐

    严重: Servlet.service() for servlet jsp threw exception java.lang.UnsupportedClassVersionError: com/ut

    严重: Servlet.service() for servlet jsp threw exception java.lang.UnsupportedClassVersionError: com/util/PostUtil  at org.apache.jsp.shouye.index_jsp._jspService(index_jsp.java:84)  at org.apache....

    Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception

    2020-04-27 22:15:44.892 ERROR 13764 --- [nio-8081-exec-9] o.a.c.c.C.[.[.[/].[dispatcherServlet] : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request ...

    spring的jar包解决:DispatcherServlet

    严重: Servlet /LogMess threw load() exception java.lang.ClassNotFoundException: org.springframework.web.servlet.DispatcherServlet 这个问题应该是spring包所带来的问题,最后还是从新下了一个spring2.5的...

    SpringMVC4.3.6配置json所需要的jar包

    SpringMVC4.3.6配置json所需要的jar包,不是使用最新最高的版本可以的,我尝试了,有错误:严重: Servlet.service() for servlet [springMVC] in context with path [/30-returnVoid-ajax] threw exception [Handler...

    关于springboot我出过的那些错误.docx

    错误八:javax.servlet.ServletException: Servlet.init() for servlet [Springmvc] threw exception 错误原因:web.xml 配置的 servlet 与实体文件不符 解决方式:检查 web.xml 配置是否正确,并确保 servlet 与...

    antlr-2.7.6rc1.jar

    严重: Servlet.service() for servlet dispatcherServlet threw exception java.lang.ClassNotFoundException: antlr.ANTLRException 当报antlr.ANTLRException错误时,只要添加一个这个jar就行了

    JSP上传图片产生 java.io.IOException: Stream closed异常解决方法

    在做 jsp 上传图片时,把 java 代码直接改成 jsp,上传时产生 如下异常: 2012-12-31 8:59:21 org.apache.catalina.core.StandardWrapperValve invoke 严重: Servlet.service() for servlet jsp threw exception java...

    解决Handler processing failed; nested exception is java.lang.NoClassDefFoundError_kmode exception

    nested exception is java.lang.NoClassDefFoundError_kmode exception" 指出的问题,是Java开发中常见的错误,通常发生在运行时。这个错误表明系统在尝试执行某个类时找不到对应的类定义。`NoClassDefFoundError` ...

    Myeclipse配置maven环境搭建.docx

    * 若启动中报 Servlet.service() for servlet jsp threw exception 错误,可能是 Maven 库生成的包与 TOMCAT 中的 servlet-api.jar,jsp-api.jar 包有冲突,进入项目文件将冲突的包删除就可以。 Myeclipse 配置 ...

    hibernate 排错 宝典1

    ### 错误二:`StandardWrapperValve[action]:Servlet.service() threw exception` **错误现象**: 这类错误往往与Struts框架结合使用Hibernate时出现,表现为Servlet服务执行失败,提示`javax.servlet.jsp....

    struts常见错误以及解决

    #### 一、`Servlet.service() for servlet jsp threw exception` 在Struts框架的开发过程中,我们经常会遇到一些常见的异常情况,这些异常不仅会打断我们的工作流程,还会影响到应用程序的正常运行。本文将针对`...

    解决struts2下载异常的jar包 struts2-sunspoter-stream-1.0.jar

    2011-1-8 20:34:20 org.apache.catalina.core.StandardWrapperValve invoke 严重: Servlet.service() for servlet default threw exception java.lang.IllegalStateException at org.apache.catalina.connector....

    javaweb编程中常见的异常及处理方法.doc

    严重: Servlet.service() for servlet action threw exception java.lang.IllegalArgumentException: argument type mismatch ``` **异常说明**:此异常表明参数类型不匹配。 **成因分析**:Struts框架中的`...

    java异常解决方案.docx

    * Servlet.service() for servlet jsp threw exception java.lang.Error: Unresolved compilation problem: + 解决方案:检查 Servlet 的配置文件是否正确,是否存在语法错误或格式不正确的问题。 * java.lang....

    SSH错误集锦

    11. “Servlet.init() for servlet action threw exception” 这个错误通常发生在后面会显示一个关于 ActionServlet 的异常堆栈信息,其中指出了异常具体出现在代码的哪一行。解决方法是检查代码,找到异常的来源,...

    request.setAttribute 语句前总显示红色感叹号解决办法 HTTP Status 500 -

    - **异常详情**:`javax.servlet.ServletException: Servlet execution threw an exception` - **根本原因**:`java.lang.Error: Unresolved compilation problem: The method setAttribute(String, Object) in the ...

    考研_计算机网络_第六学时_网络层.ppt

    因特网的路由选择协议

    java 遇到的各种异常

    `Servlet.service()` for servlet jsp threw exception: `java.lang.Error: Unresolved compilation problem`** - **异常描述**:JSP编译失败。 - **原因分析**:JSP页面中存在编译错误。 - **解决方案**: - ...

    Myeclipse配置maven环境搭建.pdf

    启动Tomcat时,如果遇到`Servlet.service() for servlet jsp threw exception`错误,可能是因为Maven生成的JAR包与Tomcat中的`servlet-api.jar`或`jsp-api.jar`冲突。此时,需要手动删除项目中冲突的JAR包,确保...

    Mybatis整合Spring 由于版本引起的BUG问题

    org.apache.catalina.core.StandardWrapperValve.invoke Servlet.service() for servlet [SpringMVC] in context with path [/tech] threw exception [Handler dispatch failed; nested exception is java.lang....

Global site tag (gtag.js) - Google Analytics