aspose file tools*
The moose likes Servlets and the fly likes Welcome file list not working Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Welcome file list not working" Watch "Welcome file list not working" New topic
Author

Welcome file list not working

prerit datta
Greenhorn

Joined: Jun 26, 2013
Posts: 16

I was trying to use my file "welcome.jsp" instead of the usual "index.jsp" in TOMCAT 7.0. But it is not working please help.Here are the files:

welcome.jsp


next.html



Here is the web.xml


index.jsp

Amit Ghorpade
Bartender

Joined: Jun 06, 2007
Posts: 2716
    
    6

Why are you having a servlet mapping for a JSP? Are you trying to implement the Front-controller pattern?


SCJP, SCWCD.
|Asking Good Questions|
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61654
    
  67

Firstly:
really? You want your servlet to be called for all request? Even images and stylesheets?

Secondly, your entry in the welcome list is not a url, it's a servlet name. Do you think that's valid?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
prerit datta
Greenhorn

Joined: Jun 26, 2013
Posts: 16

Bear Bibeault wrote:Firstly:
really? You want your servlet to be called for all request? Even images and stylesheets?

Secondly, your entry in the welcome list is not a url, it's a servlet name. Do you think that's valid?


I was just trying the concept of welcome file list. I just want to know how can I display "welcome.jsp" page as my welcome page instead of the usual index.jsp. Can you tell how will I write web.xml for this?
Jaikiran Pai
Marshal

Joined: Jul 20, 2005
Posts: 10266
    
168

Like you have listed the index.jsp, list the welcome.jsp in the welcome file listing instead of the servlet name.

[My Blog] [JavaRanch Journal]
prerit datta
Greenhorn

Joined: Jun 26, 2013
Posts: 16

Jaikiran Pai wrote:Like you have listed the index.jsp, list the welcome.jsp in the welcome file listing instead of the servlet name.


Sorry I didn't get you....
 
 
subject: Welcome file list not working