1 Reply Latest reply: Mar 6, 2012 2:58 PM by DrClap RSS

    Web application in java

      In a java web application, say MyProject, i have all the jsp pages inside a folder called "/MyProject/pages". The Home page alone is directly inside "/MyProject" . So only when i hit the url http://localhost:8080/MyProject/Home.jsp, this jsp will be opened from where i can proceed further.

      But i don't want to give the home page name in the url. For eg: If i give the url as http://localhost:8080/MyProject and press enter, i want this Home.jsp to be loaded. How do i do that?

      In web.xml, i tried to map like given below. Is it a correct approach?


      what modification should i do to make this work?
        • 1. Re: Web application in java
          That's called a "welcome page" and so you'll want to put a <welcome-file> element into your web.xml referencing that JSP. Like this, probably, depending on what level of servlet spec you're using: