jquery autocomplete how to get the id
<p>I'm attempting to use JQuery autocomplete and need to get the id of the value that was populated in the box. I'm using a hidden element to to store the id value in my html. The autocomplete works just fine and shows the results until I add the id to the array, then stops showing results.</p>

<p>This is an example of what my server code is returning.</p>

<pre><code>{"id":11,"value":"aaaa"}
</code></pre>

<p>This is the JQuery</p>

<pre><code>  $("#user").autocomplete({
    source: "/item/user.php",
    minLength: 2,
    select: function(event, ui) {
      $('#userId').val(ui.item.id);
    }
  });
</code></pre>
