Hi all. I am working on a fine way to serve some static images. Imagine a webapp a la flickr. I have some images to be served inside a slideshow AND I do not want that the real URL can be visible. In fact, there is a policy about authorization to see images, so I need my webapp to validate the request and then serve the images.
So, I cannot use the AttributeModifier and insert the "src" attribute to the image. I use a custom DynamicImageResource reading image from file system this way to implement getImageData() return IOUtils.toByteArray(new FileInputStream(image)); well, as you can guess, I have privilege problems on accessing file system within the servlet container cause my images are not stored under the webapp classpath. Now, what is for you the best way to solve this? Configure apache web server to access the directory where image files are stored and then serve them via wicket? I need to use a DynamicImageResource due to privacy as told before, so I can open a connection to httpd via HttpClient or some similar libraries and get the byte stream? Any other idea? Thanks. You can see the slideshow in action here: http://code.google.com/p/wicket-slides/ I started contributing the project some weeks ago and now it is base on smoothgallery 2.0, there is also a demo app and a maven2 pom. The code for loading resources from file is still in my app but I will publish it there when it will be enough complete. What about put that project under wicket-stuff? I can check the original author for permission. -- Daniele Dellafiore http://blog.ildella.net/ --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
