Dear JSP Community,
I have the following problem under the SUN reference implementation
jswdk-1.0:
I tried to forward a request from a servlet to a JSP page using
rd.forward(request, response),
where rd is the request dispatcher:
RequestDispatcher rd =
sc.getRequestDispatcher("/htmlgeos/AdminClient.jsp");
sc is my servlet context:
ServletContext sc = getServletContext();
/htmlgeos is mapped to my application root directory using the
configuration in 'webserver.xml':
<WebServer id="webServer">
<Service id="service0">
<WebApplication id="htmlgeos" mapping="/htmlgeos"
docBase="w:/work/htmlgeos-1"/>
</Service>
</WebServer>
Apparently the request dispatcher doesn't take care of the /htmlgeos
mapping.
It looks for AdminClient.jsp in the server's install path instead:
real path of /htmlgeos/AdminClient.jsp:
;D:\jswdk-1.0\webpages\htmlgeos\AdminClient.jsp
[which I found out using sc.getRealPath("/htmlgeos/AdminClient.jsp") ]
Putting AdminClient.jsp in the above mentioned directory works fine. But of
course this is not what I want.
(Invoking /htmlgeos/AdminClient.jsp by typing in its URL in a browser
window works, too. It also works if
I use it as a target of a POST operation in an HTML form.)
Question: is this a bug or am I doing something wrong?
Bernd
______________________________________________________________________
Der Austausch von Nachrichten mit Software Daten Service via E-Mail dient
ausschliesslich Informationszwecken. Rechtsgeschaeftliche Erklaerungen
duerfen ueber dieses Medium nicht ausgetauscht werden.
Correspondence with Software Daten Service via e-mail is only for
information purposes. This medium is not to be used for the exchange of
legally-binding communications.
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html