Skip to main content

jMaki and Spring Binding Integration

1 reply [Last post]
Joined: 2008-02-12


I have a application developed using Spring MVC. where i have written Spring binding for the HTML form elements as follows

Now i want to replace this text box to jMaki - Yahoo AutoComplete widget
How will i replace value attribute as attribute already exists in widget ??????

Thanks !

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2003-07-31


The format of the autocompleter is the same as the combobox data model:

Basically the Autocompleter is going to need to be provide a string like:

{ label : 'Alabama', value : 'AL'},
{ label : 'California', value : 'CA'},
{ label : 'New York', value : 'NY', selected : true},
{ label : 'Texas', value : 'TX'}

You could create this in the JSP or via a servlet and add it to the wiget using an EL expression.

Assuming you have created a page/request scoped string named "myval" that conforms to the one above you can then have your widget like:

Let me know if this doesn't work for you.