nate roe wrote: > > I've written a stateless auto-complete TextField by adapting Wicket's own > JavaScript and using a servlet for the back end. I don't like the servlet > and I would like to instead use Wicket to serve the auto-complete > suggestions list, but I'm not sure how. >
Well, I've just implemented a StatelessAutoCompleteTextField that works in wicket directly :) I used a similar technique to my StatlessAjaxLink described at http://www.nabble.com/Stateless-AJAX-links-td20031309.html Specifically, I copied AutoCompleteTextField and made some modifications: - replaced the AutoCompleteBehavior with a StatelessAutoCompleteBehavior and stored it in a field - implemented ILinkListener and called the autocomplete behavior's respond method from onLinkClicked StatelessAutoCompleteBehavior extends AutoCompleteBehavior with the following changes: - getStatelessHint returns true - getCallbackUrl returns a url constructed using ILinkListener.INTERFACE - onBind calls getComponent().setOutputMarkupId(true) (just like AbstractDefaultAjaxBehavior) For the record, I'm using wicket 1.4-m3 Adrian -- View this message in context: http://www.nabble.com/Directions-for-Stateless-Ajax-tp17518987p20830784.html Sent from the Wicket - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
