Try this

this.servlet.getServletConfig().getInitParameter() 


-----Original Message-----
From: Sashi Ravipati [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, June 25, 2003 9:10 AM
To: [EMAIL PROTECTED]
Subject: How to read < init-parm> defined in web.xml in an Action class


Hi

I have this entry in my web.xml file

    <init-param>
      <param-name>developer-test-id</param-name>
       <param-value>testmode</param-value>
    </init-param>

How can I get the value (testmode) in my action class.

In a servlet we I could do it like this

public void init(ServletConfig config) throws ServletException
  {
    super.init(config);
    String  ssoId = config.getInitParameter("developer-test-id");
   }

How can I achieve the same in Struts. This is required as once the
development is done and we deploy the access will be thru SingleSign On.
So I want to use this as a switch.

Thanks



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to