Java Web 项目报错The superclass "javax.servlet.http.HttpServlet" was not found on the Java Bui

Posted coding-and-teaching

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Java Web 项目报错The superclass "javax.servlet.http.HttpServlet" was not found on the Java Bui相关的知识,希望对你有一定的参考价值。

原因是你的项目配置的库有问题,没有吧Tomcat服务器的库配置进去,要重新配置

技术图片

 

添加库

技术图片

 

 

 选择Server Runtime后点击下一步

技术图片

 

 

选中Tomcat服务器,点击finish

技术图片

 

 

成功导入后就会发现少了的下图第一个库又回来了

技术图片

 

以上是关于Java Web 项目报错The superclass "javax.servlet.http.HttpServlet" was not found on the Java Bui的主要内容,如果未能解决你的问题,请参考以下文章

maven web项目的web.xml报错The markup in the document following the root element must be well-formed.(代码片段

Java Web报错:The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build

新建web工程报错:The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build

java项目报错 :A class file was not written. The project may be inconsistent...

the resource is not on the build path of a Java project报错解决

IDEA启动报错,项目无法访问:The APR based Apache Tomcat Native library which allows optimal perfor