title: how to add 2 dynamic textboxes values in jquery?
body: <p>i want addition of 2 textboxes values by jquery here is my code it is working but just only for the first row i want it also for the 2nd or third row here is the screen shot you can see that what i really want. Thanks
  <a href="https://i.stack.imgur.com/fvcd4.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/fvcd4.png" alt="enter image description here"></a>  </p>
  
  <pre><code>&lt;?php
    $query3 = mysqli_query($con,"select * from orders") or die("sdfsfs");
      while($row3=mysqli_fetch_array($query3))
      {
          $item_description = $row3['item_description'];
          $quantity = $row3['quantity'];
          $unit_price = $row3['unit_price'];
  ?&gt;
  &lt;tbody&gt;
      &lt;tr&gt;
          &lt;td&gt;&lt;label class="form-control" style="box-shadow:none;border:0px solid black;"&gt;&lt;?php echo $row3['id']; ?&gt;&lt;/label&gt;&lt;/td&gt;
          &lt;td width="400"&gt;&lt;textarea name="desc" class="form-control" style="box-shadow:none;border:0px solid black;"&gt;&lt;?php echo $item_description; ?&gt;&lt;/textarea&gt;&lt;/td&gt;
          &lt;td&gt;&lt;input id="quant" class="form-control common" name="quant" style="box-shadow:none;border:0px solid black;" type="text" value="&lt;?php echo $quantity; ?&gt;"/&gt;&lt;/td&gt;
          &lt;td&gt;&lt;input id="unit_price" class="form-control common" name="unit_price" style="box-shadow:none;border:0px solid black;" type="text" value="&lt;?php echo $unit_price; ?&gt;"/&gt;&lt;/td&gt;
          &lt;td&gt;&lt;input id="total" readonly class="form-control" name="total" style="box-shadow:none;border:0px solid black;" type="text" value=""/&gt;&lt;/td&gt;
          &lt;td&gt;&lt;span class="table-remove glyphicon glyphicon-remove"&gt;&lt;/span&gt;&lt;/td&gt;
      &lt;/tr&gt;
  &lt;?php } ?&gt;
  
  
  &lt;script&gt;
          $('#total').val(parseFloat("0"+$('#quant').val()) * parseFloat("0"+$('#unit_price').val()));
          $('.common').change(function () {
          $('#total').val(parseFloat("0"+$('#quant').val()) * parseFloat("0"+$('#unit_price').val()));
          });
  &lt;/script&gt;
  </code></pre>