Hi Guys After some more trial and error and research I have got the image to store properly and write back out a valid image using BufferedImage and ImageIO. However I am still not able to display the image. I just get the picture symbol and he link looks like <img alt="" src="./account?12-IResourceListener-profileImage">.
The code used is as follows: BufferedDynamicImageResource bufferedDynamicImageResource = new BufferedDynamicImageResource("jpeg"); bufferedDynamicImageResource.setImage(image); Image proImage = new Image("profileImage", bufferedDynamicImageResource); add(proImage); Where image is a BufferedImage. The file command outputs the following. I am running Wildfly 8.1.0. Any suggestions . Thanks David On 7 July 2014 21:18, David Beer <david.m.b...@gmail.com> wrote: > Hi All > > I am developing and application that is running on openshift. The > application is still in heavy development, using wicket 6.14 at the moment. > I am running Wildlfy 8.1.0 and testing locally. > > The problem I am facing is simply that the images that I am storing are > not being displayed on Openshift but work fine locally. I am retrieving the > image as a byte[] from the database and then displaying the Image. > > I have tried using a simple ByteArray Resource like the following: > > ThumbnailImageResource imageResource = new ThumbnailImageResource(new > ByteArrayResource("image/jpeg", userAccount.getProfileimage().getFile()), > 150); > Image profileImage = new Image("profileImage", imageResource); > add(profileImage); > > However on Openshift the image does not display. There is no error logged > just no image and the resource link does not seem to work either. > > Any thoughts would be most helpful. > > Thanks > > David >