jQuery UI Datepicker only respond to the first textbox
问题 I'm trying to create a table with multiple rows and each row has a text box for user to input the date using the jQuery UI Datepicker. The problem is that the Datepicker is only updating the text box in the first row. Here is the datepicker function in the <head> : <script> $(function() { $('.dateinput').datepicker({ dateFormat: 'dd/mm/yy' }).val(); }); </script> This is the text box: <?php while($fetch = mysql_fetch_array($query)) { echo "<td> <input type='text' id='dateinput' name=