0

I have a web application that creates QR codes and store them in C:\QR

I sometimes need to get those images and put them in a h:graphicImage.

How to get those images stored in C:\QR and put them in a h:graphicImage?

And also how to get them from their server path (I have some of them stored there)?

I have this code but it only works for the images in the "imagenes" directory...

<h:graphicImage value="/imagenes/marcas-cadillac.png" width="115" height="58"/>

I am using NetBeans 8.0

Kaz Miller
  • 949
  • 3
  • 22
  • 40
  • possible duplicate of [load the image from outside of webcontext in jsf](http://stackoverflow.com/questions/4543936/load-the-image-from-outside-of-webcontext-in-jsf) – Lukas Eichler May 26 '14 at 14:39
  • @Templar hey I checked that and I want to use option 2. But I dont know where is glassfish-web.xml in my NetBeans project. Do You know where is it or how to add it? Should I add it in web.xml? – Kaz Miller May 26 '14 at 15:02
  • It is in `web/web-inf` you can probably add it just to your `web.xml`. – Lukas Eichler May 26 '14 at 19:12
  • @Templar I added this in the xml: ` alternatedocroot_1 from=/QR/* dir=C: ` and in the view: `` but it didnt worked. The image path is: **C:\QR\1.png** what an I doing wrong? How should the path be written? – Kaz Miller May 26 '14 at 20:08

0 Answers0