0

Hi I searched could not find the answer...

Is this the best way to do this?

<h:graphicImage value="file:../../../images/image.jpg"> </h:graphicImage>

Thanks,

Scott

ScottM
  • 109
  • 1
  • 1
  • 14

1 Answers1

0

h:graphicImage renders an HTML img tag so the same rules apply for requiring that referenced images be available to whomever is viewing your resulting page. file:// protocol would require that your user have the image file available to them on their machine (or over a mount point).

You probably want to host your images on a webserver (and reference them with http:// or https:// or just :// as well), glassfish or otherwise.

You may find this thread useful jsf/glassfish hosting static files. I searched Google thusly: stackoverflow host static files on glassfish

Community
  • 1
  • 1
Jon Sampson
  • 1,473
  • 1
  • 21
  • 31