无法将项目方面动态 Web 模块的版本更改为 3.0? [英] Cannot change version of project facet Dynamic Web Module to 3.0?
问题描述
我正在使用 maven 在 Eclipse 中创建一个动态 web 应用程序.我添加了一些文件夹,如 src/test/java
和 src/test/resources
.我还更改了 Java Build Path 中的库以获得 JavaSE-1.7.到这里一切正常.
I am using maven to create a dynamic webapp in Eclipse. I added some folders like src/test/java
and src/test/resources
. Also I changed the library in Java Build Path to obtain the JavaSE-1.7. It's all OK up to here.
当我尝试更改 Projects Facet 动态 Web 模块时出现问题.我在同一个地方将 Java 更改为 1.7.它仍然告诉我,无法将项目方面动态 Web 模块的版本更改为 3.0.
When I tried to change the Projects Facet Dynamic Web Module something went wrong. I had change the Java to 1.7 in the same place. And it still told me, cannot change version of project facet Dynamic Web Module to 3.0.
我已经改变了所有会影响我认为改变的东西.
I have changed everything that would effect the changing I think.
推荐答案
我更新了我的 web.xml
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
version="3.0">
<display-name>Servlet 3.0 Web Application</display-name>
</web-app>
然后只是 Maven -> 更新项目 ...
这篇关于无法将项目方面动态 Web 模块的版本更改为 3.0?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!