Setting the default/welcome page for a JSF app

Since <welcome-file-list> only works with physical files, you cannot use a *.jsf filename here since this resolves to a different physical file (like *.xhtml).

To define a welcome file, use one of the following approaches:

    • add an index.html file, and include a refresh meta tag in the head:

      <head>
      <meta http-equiv="Refresh" content="0; URL=your_welcome_page.jsf">
      </head>

 

  • add an index.jsp file, and redirect to your welcome page:

    <% response.sendRedirect("dropdowns.jsf"); %>

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.