The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
在maven项目中,新建jsp页面,出现错误:
The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
如图:
这是因为检测到它不是web项目,找不到httpServlet引用包,
解决方法:
鼠标放到项目上—》右键—》选择properties—》找到Project Facets,勾选Dynamic Web Module 和Runtimes中的tomcat容器,如图:
点击Apply,OK,即可解决
还没有评论,来说两句吧...