0

I would like retrieve String parameter from a file in a web service (jax-ws). I've see that I can't read parameters from web.xml using FacesContext. This code don't work:


fc = FacesContext.getCurrentInstance(); String fileOpzionali = fc.getExternalContext().getInitParameter("fileOpzionali");
Suggest?

Thanks

1 Answers1

0

Do you have a corresponding entry like this in your web.xml:

    <context-param>
       <param-name>fileOpzionali</param-name>
       <param-value>VALUE</param-value>
    </context-param>

?

planetjones
  • 12,469
  • 5
  • 50
  • 51
  • @idarios then it should work I think. Try getting the ServletRequest and getting the parameter that way e.g. request.getSession().getServletContext()... – planetjones May 18 '11 at 14:16