这是我第一次尝试自己建立一个web应用程序项目,由于某些原因,我甚至不能让它在hello world设置下工作。我将所有内容都设置为default,选择要编译的JDK1.8和一个包含只包含文本的index.html页面的Tomcat7服务器。在将项目添加到服务器后,我应该能够右键单击项目并在服务器上运行,但即使在这个简单的设置中,我仍然得到404。我遗漏了什么?

Web.xml欢迎列表:
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>发布于 2014-11-18 11:32:43
无法直接访问WEB-INF文件夹下的文件。容器将在WEB-INF/classes中查找类,并且WEB-INF下的JSP文件可以包含在其他jsp中,但是在那里请求资源的任何浏览器都将得到404响应。
您应该将index.xhtml路径从webapp/WEB-INF/index.html更改为webapp/index.html,以与您的web.xml对应
https://stackoverflow.com/questions/26985862
复制相似问题