1 Reply Latest reply on May 11, 2010 5:26 AM by Ilya Shaikovsky

    How to get path address

    kinson jiang Newbie

      I put pictures under /deploy/jboss-web.deployer/ROOT.war/images/ 


      From my jsf page in the one project when I try to display these images:


      <h:graphicImage value="{url}" />


      url had to put full address like http://localhost/images/picture01.jsf to display.


      I can have following functions to get this address:


      FacesContext.getCurrentInstance().getExternalContext().getRequestHeaderMap().get(name) + "/images/picture01.jsf";


      But I had to put "http://" in the front of this address, otherwise, it cannot display pictures, I have no idea why. So the problem is when this website support SSL, then it is not easy to return correct full address. any suggestion/