Thanks for the reply, but perhaps my question wasn't clear? (I don't
see how this excerpt from the javadoc helps - I've read this before
and remain perplexed.)
When obtaining a request dispatcher, I do provide a a pathname beginning
with a "/" which should be interpreted relative to the context root.
What I'd like to know is if there is any specification as to when a
ServletContext "cannot" return a RequestDispatcher.
As far as I can see with Weblogic 5.1 (and I tried this with JRUN 2.3.3 as
well), the ServletContext always returns a RequestDispatcher, regardless of
whether or not the requested resource actually exists. I've tried
dispatching
to both non-existent .jsp files, and .html files. In both cases, I receive
a non-null dispatcher. (Sam Pullara suggested that the issue with .jsp
files might be that the target of the dispatcher is actually a JSP
parsing/compiling
servlet in these implementations. Since this servlet exists, the returned
dispatcher is non-null. If this were the case, however, then dispatching to
.html files should have had a different result.)
Thanks again for your time.
-AMT
> -----Original Message-----
> From: A mailing list about Java Server Pages specification and reference
> [mailto:[EMAIL PROTECTED]]On Behalf Of Scott Evans
> Sent: Wednesday, June 14, 2000 7:54 AM
> To: [EMAIL PROTECTED]
> Subject: Re: ServletContext.getRequestDispatcher
>
>
> Here's your answer - straight out of the Servlet API javadoc:
>
> "The pathname must begin with a "/" and is interpreted as relative to the
> current context root. Use getContext to obtain a RequestDispatcher for
> resources in foreign contexts. This method returns null if the
> ServletContext cannot return a RequestDispatcher ."
>
> Scott Evans
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets