This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Servlets and the fly likes Setting the path of servlet and jsp pages Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Setting the path of servlet and jsp pages" Watch "Setting the path of servlet and jsp pages" New topic
Author

Setting the path of servlet and jsp pages

JayaSiji Gopal
Ranch Hand

Joined: Sep 27, 2004
Posts: 303
I have a web application which has the following directory structure:



I have my web.xml as follows:



What changes should I do to web.xml so that -

1) after logging into the application, index.jsp is displayed.
2) when i click on any link on index.jsp, it finds the servlet and shows up the next right jsp page with the styles.

index.jsp is -



I have pasted only important pieces of index.jsp.

Right now, what happens is -

1)i login, it does not find index.jsp and it shows up directory structure on the browser as jsp and styles.
2) i click on jsp, it shows up index.jsp, but does not find the stylesheet.
3) in index.jsp, i click on add mcd user, it finds add_mcd_user.jsp but no stylesheet.


SCJP 1.4, SCWCD 1.4<br /> <br />Thanks in advance!<br />Jayashree.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60740
    
  65

The base of your web app should be the folder containing WEB-INF.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
wood burning stoves
 
subject: Setting the path of servlet and jsp pages
 
Similar Threads
web.xml deployment problem
Switching from Reference Implementation to MyFaces
s:excelExport Exception in PhaseListener
Chaining filter servlet
DBUnit, why insert test data, only to delete/re-create tables after?