0

我有两个文件 - 1) JSP 文件 2) HTML 文件

每当我运行项目时,jsp 都会首先执行。我怎样才能先运行 HTML 呢?

4

2 回答 2

0

更改 web.xml 文件的结构:

<welcome-file-list>
 <welcome-file>Name of the html file</welcome-file>
</welcome-file-list>
于 2013-05-06T06:20:07.620 回答
0

web.xml您可以提供您需要首先显示的文件。

默认情况下,它是下面的一个。

<welcome-file>index.html</welcome-file>

所以在这里给你的 html 文件名。

<welcome-file>MyHtml.html</welcome-file>
于 2013-05-06T06:21:52.053 回答