On 7/12/07, verbal evasion <[EMAIL PROTECTED]> wrote:

actually, doing url.getContent() doesnt seem to work. can someone please
help me out?


in your markup just do <img src="img/foo.gif"/> wicket will rewrite that url
to be context-relative so /mycotnext/img/foo.gif which will map to
webapp/img/foo.gif

-igor



thanks,

verbal

On 7/12/07, verbal evasion < [EMAIL PROTECTED]> wrote:
>
> so i realized that i probably just want to access the image via a URL.
> the question now is i cant seem to access it with a relative page. do you
> think i should just URL.getContent() and then save it in my
> WebApplication? seems weird, but whatever i guess. i would still like to
> find out how to figure out the "header" of the URL from the current running
> context.
>
> thanks,
>
> verbal
>
> On 7/12/07, verbal evasion < [EMAIL PROTECTED]> wrote:
> >
> > i am deploying my web application (including website using wicket) in
> > an ear. there are files in the ear under the webapp/img directory and i
> > would like to load them to use with Image and ImageMap. I dont know how to
> > specify the path. i do not want to use the absolute FS path. i would like to
> > specify the path relative to the webapp directory so i can just do like
> > "/img/mypicture.png". i dont know how to do that. i can read the image from
> > a database by using a Resource and overriding getResourceStream or use an
> > image resource and overwrite getImageData, but what's the best way to load
> > an image file thats in the ear? maybe this isnt such a wicket question but
> > more of an ear question. thanks for the help anyway.
> >
> > verbal
> >
>
>

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to