Hi Guys

You may find this discussion useful about reading from databases as well.
http://apache-wicket.1842946.n4.nabble.com/Displaying-Images-Stored-in-DB-on-Openshift-td4666463.html#a4666595

Thanks

David

On 26 March 2015 at 02:26, sabmoonie <sabmoo...@gmail.com> wrote:

> I've been searching for solutions on how to show an image using its
> location(absolute path) and your code helped me a lot. Been under stress
> the
> past days due to this problem. Thanks Mr. ORACLEADF!
>
> Btw, for those who wants to know how to convert a File() to byte[] use
> this:
>
> try {
>     File file = new File(imagefilePath);
>     byte[] byteArray = new byte[file.length()]();
>     byteArray = FileUtils.readFileToByteArray(file);
>  }catch(Exception e){
>      e.printStackTrace();
>
>  }
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/show-image-retrieved-from-database-tp4658009p4670098.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

Reply via email to