jQuery plugin that suggests/autocompletes within a textarea

Trufa picture Trufa · Dec 1, 2010 · Viewed 10.6k times · Source

Is there a jQuery plugin that suggests/autocompletes within a textarea?

What I want is to have suggested words or autocompleted text proffered to the user in a textarea like the example image below:

autocomplete box demo

Answer

Breezer picture Breezer · Dec 1, 2010

Well there is the autocomplete plugin that does just that, and if you want to pull data from a database I recomment using the ajax API that is included in jQuery.

something like this

$('textarea').keyup(function(){
  $.post('ajax/test.php', function(data) {
   $('#example').autocomplete(data);

   });

});

Also remember this is just the basic structure to give you an idea.

P.S. I just found this it should fill all your needs.