title: In jquery UI autocomplete feature add a buttons at the end of each item in the list
body: <p><a href="https://i.stack.imgur.com/Dypmt.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Dypmt.png" alt="enter image description here" /></a>
  I have created the list using jQuery Ui autocomplete now wanted to display 3 buttons to the end of each item in the list, I have tried the following code for single button but its not working for me,kindly guide me for this.</p>
  <p>I have used _renderItem to render the button at the end of each item in the list.</p>
  <pre><code>...).data(&quot;ui-autocomplete&quot;)._renderItem = function(ul,item){
  var addTobag = $('&lt;input/&gt;').attr({type:'button', name:'bag',class:'btn btn-primary' , value:'Add to bag',style:'float : right'});
  return $('&lt;li&gt;&lt;/li&gt;').append('&lt;span&gt;' + item.label + addTobag'&lt;/span&gt;' )
  };
  </code></pre>
  <p>It displays me error as undefined[object object]</p>