Datepicker passing parameters on select/close?

Datepicker passing parameters on select/close?

When datepicker closes the calendar window I'd like to pass both the date and the id of the <input> tag in the code below.  The documentation mentions 'this' but no info on how to use it or how to use 'inst'.  Thanks!
  1. $( "#testdate" ).datepicker({
       changeMonth: true,
       changeYear: true,
       onClose: function(dateText, inst) { passvals(dateText,inst); }
      });
     });




  2. <input type='text' id='testdate' name='testdate'>