建立了一个Javaweb工程,并在eclipse中配置了Web容器Tomcat。新建的jsp页面,添加一个简单的Java类。可是,JSP页面顶端出现“红色”的报错信息:The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path。原来Javaweb工程类中没有添加Tomcat运行时相关类导致。解决方法是点击自己所建的Web工程,选择build path,点击configure build path,然后找到 Libraries,选择 add Library 。选择myeclipse server library 。选择自己的tomcat服务器。点添加即可。
相关文章
- The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path。问题
- java开发eclipse常见问题(一)The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
- 异常-----The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path。
- jsp页面提示“Multiple annotations found at this line: - The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path”解决方案
- The superclass “javax.servlet.http.HttpServlet" was not found on the Java Build Path错误
- web项目jsp出现The superclass javax.servlet.http.HttpServlet was not found on the Java Build Path错误
- maven The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path错误
- The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path解决方案
- JSP报错:The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
- Eclipse导入JavaWeb项目报错:The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path