Use ByteArrayResource instead that loads the image's bytes from wherever
you need.


On Wed, Dec 26, 2012 at 2:54 PM, Delange <[email protected]> wrote:

> In my webapplication a user can upload images. They are displayed on other
> pages.
>
> When I start the application with Jetty from the Eclipse directory, all
> images are stored directly under the project folder.
> But when I want to display them, they must be under src/main/webapp/
> The is caused by the ContextRelativeResource. If I don't use this it
> doesn't
> work
>
> Has anyone a solution for this strange effect?
>
> My directory structure in eclipse is:
> mywebapplication
>     images
>            photos
>                   pic001.jpg
>     src
>            main
>                  java
>                         ...
>                  resources
>                          ...
>                  webapp
>                         images
>                              photo
>                                   pic001.jpg
>
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/How-to-resolve-right-path-for-variable-images-with-Jetty-tp4655058.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>


-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com <http://jweekend.com/>

Reply via email to