Demo of Autocomplete minLength Option JQuery UI

Change this to




Change the minLength add observe when the menu is displayed

Words available : source:["PHP", "JQuery", "JavaScript", "HTML", "ASP", "Perl", "MySQL","Access","Excel","Dot Net"]



HTML

<input id=auto_c>
<div id=d1></div>
Change this to 
<div class='radio-inline'>
  <label><input type='radio' name='r1' id='r1' value='0' checked>0</label>
</div>
<div class='radio-inline'>
  <label><input type='radio' name='r1' id='r1' value='1' >1</label>
</div>
<div class='radio-inline'>
  <label><input type='radio' name='r1' id='r2' value='2' >2</label>
</div>
<div class='radio-inline'>
  <label><input type='radio' name='r1' id='r2' value='3' >3</label>
</div>
<div class='radio-inline'>
  <label><input type='radio' name='r1' id='r2' value='4' >4</label>
</div>
<div class='radio-inline'>
  <label><input type='radio' name='r1' id='r2' value='5' >5</label>
</div>

jquery

<script>
$(document).ready(function() {
////////////////
$( "#auto_c" ).autocomplete({
  source: [ "PHP", "JQuery", "JavaScript", "HTML", "ASP", "Perl", "MySQL","Access","Excel","Dot Net" ],
 });
///////////////
var status_used = $( "#auto_c" ).autocomplete( "option", "minLength" );
$('#d1').html( " <b>Value of minLength    :  </b>: " + status_used );
//////////
$("input:radio[name=r1]").click(function() {
var sel=$(this).val()
$( "#auto_c" ).autocomplete( "option", "minLength", sel );

var status_used = $( "#auto_c" ).autocomplete( "option", "minLength" );
$('#d1').html( " <b>Value of minLength    :  </b>: " + status_used );
})
///////////////////////
})</script>