| Author |
Mapping a request to a JSP in WEB.XML
|
Gregg Bolinger
Ranch Hand
Joined: Jul 11, 2001
Posts: 15230
|
|
This is probably something simple I am just missing, but I would like to map a request to a JSP instead of a Servlet (yes, I know jsp's are servlets) in the web.xml file. I believe this will keep me from having to code "dummy" servlets just to forward a request to the correct view. I shouldn't have too many of these since there will be some pre-processing for most of my Views (filling combo boxes, etc) but I will have a few. I think I would be able to map the request to the actual servlet that the app server converts the JSP to. Something like package.jsp_nameofjsp, but I am not sure. Thanks.
|
 |
Andres Gonzalez
Ranch Hand
Joined: Nov 27, 2001
Posts: 1561
|
|
hmm how about : You will be declaring a servlet named XYZ and map it to the jsp file located in <documentRoot>/yourJSPFile.jsp. So, if you access your XYZ servlet it will print whatever you have in your jsp file. is this what you're after? hope this helps
|
I'm not going to be a Rock Star. I'm going to be a LEGEND! --Freddie Mercury
|
 |
Gregg Bolinger
Ranch Hand
Joined: Jul 11, 2001
Posts: 15230
|
|
Originally posted by Andres Gonzalez: hmm how about : You will be declaring a servlet named XYZ and map it to the jsp file located in <documentRoot>/yourJSPFile.jsp. So, if you access your XYZ servlet it will print whatever you have in your jsp file. is this what you're after? hope this helps
Figured it was something as easy. Thanks, I will give it a shot.
|
 |
Gregg Bolinger
Ranch Hand
Joined: Jul 11, 2001
Posts: 15230
|
|
|
Awesome Andres! Thanks.
|
 |
 |
|
|
subject: Mapping a request to a JSP in WEB.XML
|
|
|