You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Danilo Luiz Rheinheimer <da...@floripa.com.br> on 2002/04/22 14:16:41 UTC

Servlet context

   Hi,

   On another list someone talk about use servletcontext to get a resource :

   InputSource sn = new 
InputSource(oCtx.getResourceAsStream("Accessinfo.xml")); // (oCtx is your 
ServletContext object)

   But how I can do it on a Struts application ? I want to do it on the 
perform method of a action. So how I can get a ServletContext object ?



----
Danilo Luiz Rheinheimer
Florianopolis/SC Brasil
Sony CliƩ 615C
mailto:danilo@floripa.com.br
----


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Servlet context

Posted by Elmar Knipp <El...@knipp.de>.
On Mon, 22 Apr 2002, Danilo Luiz Rheinheimer wrote:

>    But how I can do it on a Struts application ? I want to do it on the
> perform method of a action. So how I can get a ServletContext object ?


   ... = request.getSession ().getServletContext ().get...


Regards,
Elmar


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>