新建maven指定jdk版本-eclipse新建maven项目报错The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path的解决方案
具体表现为:
使用Eclipse+Maven建立了一个Javaweb工程,JSP页面顶端出现“红色”的报错信息:The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path。
解决方法:
在pom.xml中的 <build></build>中 添加:
<plugins>
<!-- 编码和编译和JDK版本 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
<encoding>utf8</encoding>
</configuration>
</plugin>
</plugins>
然后Maven > Update project即可
如果报错:
Java compiler level does not match the version of the installed Java project facet. xxx Unknown Faceted Project Problem (Java Version Mismatch)
可以:项目--properties---project Facets设置java文件的版本为 1.8(自己对应上面步骤的jdk)

新建maven指定jdk版本-eclipse新建maven项目报错The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path的解决方案的更多相关文章
- eclipse中web工程新建jsp文件报错: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 ...
- 新建jsp报错“The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path”
今天新建jsp文件时,就报错“Visual Page Editor has experimental support for Windows 64-bit”,然后刚好stackoverflow上面有这 ...
- [IDE - Eclipse] JSP报错:The superclass “javax.servlet.http.HttpServlet” was not found on the Java Build Path
是因为Eclipse的Web项目不自动引入相关jar包. Right Click on the Project ❯ Properties ❯ Project Facets. You would be ...
- 使用maven创建项目时报错The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
Description Resource Path Location Type The superclass "javax.servlet.http.HttpServlet" wa ...
- java eclipse maven The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path 解决方法
在eclipse 中使用maven 创建java web项目,启动服务器遇到提示:The superclass "javax.servlet.http.HttpServlet" w ...
- Eclipse中新建Maven Web项目报错:The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
在maven web项目中的index.jsp中的错误信息如下: The superclass "javax.servlet.http.HttpServlet" was not f ...
- maven新建web项目提示The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
maven新建web项目提示The superclass "javax.servlet.http.HttpServlet" was not found on the Java Bu ...
- maven项目The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
用Eclipse创建了一个maven web程序,使用tomcat8.5作为服务器,可以正常启动,但是却报如下错误 The superclass "javax.servlet.http.Ht ...
- 新建 jsp异常,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.htt ...
随机推荐
- IE 此网站的某个加载项无法运行
1.使用IE浏览器 发生问题,一直以为是浏览器安全设置出问题,将IE安全级别调到最低,还是同样的问题 2.转用360浏览器(IE内核) 问题一样,提示略有不同 点击需要运行的java程序 解决方法 1 ...
- eclipse Maven 使用记录 ------ 建立app项目
maven 项目构建工具 , 如今已逐渐取代ant的笨拙配置方式 ,使项目管理更加简单,规范,结构更加清晰,这里记录跟eclipse集成的一些步骤 1.从apache maven项目下下载maven ...
- ACCESS_REFUSED - Login was refused using authentication mechanism PLAIN
问题描述:FatalListenerStartupException: Authentication failure 问题原因:连接RabbitMQ服务器异常,要么是用户名和密码错误,要么是使用的用户 ...
- centos7永久更改主机名
操作环境: [root@bogon ~]# uname -a Linux #localhost.localdomain 3.10.0-514.el7.centos.plus.i686 #1 SMP W ...
- C#如何调用R
1. 现在R中安装rscproxy库 > install.packages(rscproxy) > library(rscproxy) 2. 到这个网站http://rcom.univ ...
- 【Unity Shader】四、高光反射Specular Shader例子
http://www.cnblogs.com/guxin/p/unity-diffuse-shader-demo.html 在上文中已经学习了漫反射Diffuse Shader和环境光,现在再在此基础 ...
- WPF样式继承
场景:样式A和样式B的背景颜色一样,但是文字颜色不一样 <Style x:key="BaseStyle" TargetType="Button"> ...
- docker 运行redis
自从接触docker之后,很多软件都想着用docker运行,毕竟手动安装的话老是要配一些环境变量啊,找配置文件修改配置什么的,docker却有更简便的办法. 正题: 建一个docker应用容器可以通过 ...
- android开发(44) 使用了 SoundPool 播放提示音
SoundPool 一个声音播放的辅助类,从名字可以看出,它具有 “池”的能力,它先加载声音文件到内存,以支持多次播放声音文件. 特点 SoundPool适合 短小的 声音文件 SoundPool适合 ...
- Shell数组遍历
#!/bin/bash emp_info=( aaa aaa@qq.com bbb bbb@qq.com ccc ccc@qq.com ddd ddd@qq.com eee eee@qq.com ) ...