I see. I looked through the Servlet Spec 2.3 and no restrictions are found to have multiple context paths mapped to one web application. But how such capability is utilized in a servlet container? I do not find information on how to map multiple context paths to one web application. Is this container vendor specific thing?
Another thought that is surprising me is that a web application could not assume its context paths are *constants* in the application life cycle. Is this assumption valid in general? (Of course one should not change context paths very often even if they could be changed.) Jing ----- Original Message ----- From: "Craig R. McClanahan" <[EMAIL PROTECTED]> To: "Struts Users Mailing List" <[EMAIL PROTECTED]>; "Jing Zhou" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Thursday, July 31, 2003 10:57 AM Subject: Re: Could one figure out the context path in Servlet.init() method? > > > On Thu, 31 Jul 2003, Jing Zhou wrote: > > > > > I am wondering if there is a way to get the context path without > > using init parameters during the initialization of a servlet. > > Any clues? We have ServletContext.getRealPath(), but not > > the ServletContext.getContextPath(). Why can't the ServletContext > > tell me its context path? > > > > You are assuming that a web applicaton only has one context path. That > does not have to be the case. > > > Jing > > Craig > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]