You can create the DOM element using custom javascript (it's very simple, basic DOM manipulation) invoked from ajaxRequestTarget.prependJavascript(). Be sure that the id attribute of new DOM element is same as new list item id.
Then just render the newly created item (target.addComponent) which you create manually during the ajax request. Actually, rather then using ListView for this, I suggest you using RefreshingView, as it's more flexible. -Matej On 6/24/07, Peter Thomas <[EMAIL PROTECTED]> wrote: > Hi, > > I'm trying to create a kind of "expression builder" UI, so I was thinking of > a ListView and there is this "add" button on the page that will add an item > to the List. I am able to do this over Ajax, and I am aware that to refresh > a ListView over Ajax, you have to target a container of the ListView and all > this is working fine. But this means that in the Ajax response, the HTML > for the entire list is retrieved from the server. > > Since the list may get big and the content is complex, is it possible to > only get the last ListItem and do a DOM "append" operation over Ajax? Does > Wicket's built in Ajax support this. Any ideas would be appreciated. > > Thanks, > > Peter. > > ------------------------------------------------------------------------- > 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