I\'m attempting to do some calculations for a \"running total\", this is my code:
$(\'.quantity_input\').live(\'change\',function(){
Closest will find the closest ancestor (parent, grandparent), but you will then need to do a find in order to find the correct element to update. For example, if you have an element in a table row and you need another element in that same row:
$('.myElement').closest('tr').find('.someOtherElement');
Edit:
In your case, you will want
$(this).closest('tr').find('.cost_of_items').text(totalTotal.toFixed(2));