The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的异常的原因及解决办法
来源:互联网 发布:雄迈cms客户端 编辑:程序博客网 时间:2024/05/29 19:54
最近在学Acegi,就试着运行一个小例子,不成想抛出下面的异常org.apache.jasper.JasperException: Unable to compile class for JSP: An error occurred at line: 23 in the generated java fileThe method getJspApplicationContext(ServletContext) is undefined for the type JspFactoryStacktrace: org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:92) org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330) org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:423) org.apache.jasper.compiler.Compiler.compile(Compiler.java:308) org.apache.jasper.compiler.Compiler.compile(Compiler.java:286) org.apache.jasper.compiler.Compiler.compile(Compiler.java:273) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266) javax.servlet.http.HttpServlet.service(HttpServlet.java:803)上网搜,发现不少人有这个问题,但都没有解决办法。后来想到可能和tomcat6有关,因为我在工程的lib中添加了很多包(一堆什么Spring依赖),所以把他们一删JSP就不抛异常了。我估计是,工程中和tomcat6 lib中重复的包在加载时是先被加载(也就是tomcat6中相同的包没有被加载),而工程中的包版本要比tomcat6中的低,造成上面的异常。我对照着tomcat中包,发现工程中出现诸如catalina.jar、jsp-api.jar、servlet-api.jar等这样的重复包,把它们从工程中删了就应该行了(对于上面的异常,原因应该是包jsp-api.jar)。看来不是什么包都可以一股脑往工程里加阿。
0 0
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的异常的原因及解决办法
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的异常的原因及解决办法
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory!
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory非包冲突的解决方法
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory 错误的解决
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的解决方法
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的解决方法
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的解决方法
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的解决方法
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的解决方法 最近又开始
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的解决方法
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的解决方法
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的解决方法
- 异常:The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory问题查找及解决
- android 默认隐藏输入法软键盘
- PHP中双引号和单引号的区别
- unity移动端内存优化——NGUI
- android基础学习之有没有标签基础设置
- android 各种常用默认设置项的参考【1】
- The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory的异常的原因及解决办法
- 剑指offer-面试题40:数组中只出现一次的数字
- android 神奇的android:clipChildren属性
- IntelliJ IDEA 常用快捷键
- nexus 搭建私服简单步骤
- SQLite和Berkeley DB(BDB)比较资料收集
- 纪念一下我的短暂的ios时光
- HTML基础
- java基础(四),数据类型转化,Date,Calendar