Thies Edeling wrote:
> Hi,
> 
> This must have been asked a zillion times but I couldn't find the right 
> answer in the list archives. Anyway, I have some javascript which does 
> an image replacement on a mouseover (need a JS version for browser 
> compatibility :( ).
> AFAIK JavaScriptReference doesn't update image paths in the javascript 
> such as StylesheetReference does with CSS (btw, saw in the archives that 
> the plan was to include it in 1.3, was it dropped?). So now I'm 
> replacing variables using PackagedTextTemplate which works fine except 
> that I can't find an easy way to construct relative paths to images in 
> the /img dir of my war. I was expecting getPageRelativePath to help but 
> it didn't work.  thx :)

On 1.3.0-SNAPSHOT, you want the Request#getRelativePathTo*() functions.

See the thread "Confused about relative paths and my CSS" for the 
reasoning behind context-relative stuff in CSS.

Regards,

Al
-- 
Alastair Maw
Wicket-biased blog at http://herebebeasties.com

-------------------------------------------------------------------------
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