exception
org.apache.jasper.JasperException: Unable to compile class for JSP
No Java compiler was found to compile the generated source for the JSP.
This can usually be solved by copying manually $JAVA_HOME/lib/tools.jar from the JDK
to the common/lib directory of the Tomcat server, followed by a Tomcat restart.
If using an alternate Java compiler, please check its installation and access path.
这个异常一般是
1- jsp文件编写错误,里面可能包含错误的代码。
2 - 是你的jdk没有配置好。环境变量或路径设置不对。
还有,用浏览器打开:http://localhost:8080
如果出现提示成功画面,那说明八成是JSP文件有问题。
一般要把jsp文件放在ROOT目录下才可以正常运行。
本文探讨了JSP编译时出现的exceptionorg.apache.jasper.JasperException异常,并提供了详细的解决方案,包括检查JSP文件语法、确认JDK环境配置正确及复制tools.jar到Tomcat的lib目录等步骤。
8549

被折叠的 条评论
为什么被折叠?



