Olá,
uma duvida como faço pra carregar a pagina index.xhtml ao digitar
http://localhost:8080/ProjetoJSF sem precisar digitar index.jsf
Se alguém puder me ajudar e me informar o que estou fazendo de errado.
abs
index.xhtml
<?xml version="1.0" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
>
<h:head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<title>Gerenciador Financeiro Pessoal</title>
</h:head>
<h:body>
<h1>Gerenciador Financeiro Pessoal</h1>
<h:form>
<h:commandLink action="#{usuarioBean.novo}">Novo Usuário</h:commandLink>
</h:form>
</h:body>
</html>
web.xml
<display-name>FinanceiroWeb</display-name>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>index.jsf</welcome-file>
</welcome-file-list>
<servlet>
<display-name>FacesServlet</display-name>
<servlet-name>FacesServlet</servlet-name>
<servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>FacesServlet</servlet-name>
<url-pattern>*.jsf</url-pattern>
</servlet-mapping>
faces-config.xml
<managed-bean>
<managed-bean-name>usuarioBean</managed-bean-name>
<managed-bean-class>financeiro.web.UsuarioBean</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
</managed-bean>
<navigation-rule>
<from-view-id>*</from-view-id>
<navigation-case>
<from-outcome>inicio</from-outcome>
<to-view-id>index.xhtml</to-view-id>
</navigation-case>
<navigation-case>
<from-outcome>usuario</from-outcome>
<to-view-id>/usuario.xhtml</to-view-id>
</navigation-case>
</navigation-rule>
<navigation-rule>
<from-view-id>/usuario.xhtml</from-view-id>
<navigation-case>
<from-outcome>sucesso</from-outcome>
<to-view-id>/mostraUsuario.xhtml</to-view-id>
</navigation-case>
</navigation-rule>