Hi, I'm having a problem with a component that uses a PackagedResourceReference. Here is the setup:
I'm using Wicket 1.5.10 with wiquery 1.5.7. I've extended DatePicker<T> to add a custom image fur the widget. The relevant part f the constructor looks like this: PackageResourceReference pcgRef = new PackageResourceReference(BrDatePickerField.class, "calendar.gif"); String url = urlFor(pcgRef, null).toString(); setButtonImage(url); Now I'm using the BrDatePickerField in a RepeatingView. It is used for users to submit cost points. For example "On Jan/31/2013: 34,23$". This view has a button that adds additional rows. The button just adds a new item to the list that is shown by the RepeatingView. When the View is rendered initially the calendar.gif shows up correctly for all rows that have already been added to the data store: ../resource/com.mypackage.wutils.BrDatePickerField/calendar-ver-1378812639389.gif However, if I add a new row the icon will not show up in the new row. The url for the new row is: ./resource/de.brunata.online.wutils.BrDatePickerField/calendar-ver-1378812639389.gif I believe this has something to do with the request URL, because I know that the UrlRender uses the client Url somewhere. If I debug the constructor of the BrDatePickerField, I can see that in the inital call getRequest().getClientUrl() = wicket/bookmarkable/com.mypackage.PageThatUsesBrDatePickerField If I press the add Row button it will become: getRequest().getClientUrl() = wicket/page?15-1.IFormSubmitListener-fHnKosten I have already tried to use a context relative resource, but this doesn't help. I've also tried to hack the constructor of the BrDatePickerField by adding a ../ if it is missing, but this will break the icon on other pages. Can anybody help here? TIA! Benedikt -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Problem-when-adding-component-with-PackagedResourceReference-during-submit-tp4661896.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