将index.html更改为index.jsp(JavaEE + Glassfish) [英] Change index.html for index.jsp (JavaEE+Glassfish)

查看:173
本文介绍了将index.html更改为index.jsp(JavaEE + Glassfish)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个小问题. 是否可以删除" index.html并创建(以替换index.html)index.jsp?怎么样?

I have a little problem. Is it possible 'delete' index.html and create (to replace index.html) index.jsp? How?

我没有找到要更改其主页(index.html)地址(针对index.jsp)的文件(web.xml,glassfish-resource.xml). 我没有在互联网上找到答案...

I don't find any files (web.xml, glassfish-resource.xml) with the address to the home page (index.html) to change it (for index.jsp). I have not found an answer on the Internet...

感谢您的回复!

推荐答案

您需要为应用程序配置欢迎文件列表".默认情况下,它是index.html,这就是为什么您找不到定义它的原因.

What you need is to configure the welcome-file-list for your application. By default, it's index.html, which is why you don't find anything defining it.

看看 web.xml部署描述符元素您基本上需要

<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>

这篇关于将index.html更改为index.jsp(JavaEE + Glassfish)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆