Jquery UI autocomplete on dynamic fields

Jquery UI autocomplete on dynamic fields

Kindly have a look at this screen capture.


as i have shown i am trying to use jquery ui autocomplete on a dynamically generated fields, autocomplete works fine with the main field i'm using to copy & generate dynamic fields. but when adds a new field the autocomplete not working with the newly generated field.

this is my autocomplete code

  1. $(function(){
  2.   $(".get-tasks").autocomplete({
  3.    source: baseurl+"job/job/get_tasks_autocomp",
  4.   });
  5. });


I would like to get help from someone here to fix this, please show in Code how can i fix this.