[jQuery] JQuery Autocomplete Values/Presetting

[jQuery] JQuery Autocomplete Values/Presetting


I'm using the JQuery Autocomplete plug-in and having a great deal of
difficulty setting the value of the field either in advance (before
making it an autocomplete) or after page load.
To start, I have a standard text box and was just echoing a value from
php into the value="" param. Then, on page load, I set the input to
autocomplete. That would wipe out the value I had entered.
Next I tried setting it after setting the input as an autocomplete.
That looked like it worked, but it really doesn't sync to the values
in the search list.
For more info, I am using a value/id array as the search values. For
those unfamiliar, the array is structured like:
[ ['One',1], ['Two',2], ['Three',3] ]
The autocomplete functionality works great and result gives me the ID,
I just cannot seem to figure out how to preset the value to 2 and
display 'Two', for example.
Any help greatly appreciated!
Erick