skip to Main Content

How I use jQuery "each()" inside HTML table?

Look at the HTML table below: $(document).on('change', '[name="item_inline"]', function(e) { var $this = $(this); var $inp = $this.closest('tr').find('[name="rtn_qty[item_id]"]'); var qty = $this.closest('tr').find('.qty').text(); $inp.val(qty); }) <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <table> <thead> <tr> <td><input type="checkbox" name="select_all" id="select_all" value="1"></td> <td>Item Name</td> <td>Qty</td> <td>Return Qty</td> </tr>…

VIEW QUESTION
Back To Top
Search