title: Multiply Cell Values of each Rows Dynamically
body: <p>I have this jQuery script for adding a table row based on each <em>td</em> and it works great.</p>
  
  <pre><code>$(document).ready(function(){
      $(".saisie").each(function() {
          $(this).keyup(function(){           calculateTotal($(this).parent().index());
          });
      });
  });
  
  function calculateTotal(index)
  {
     var total = 0;
      $('table tr td').filter(function(){
          if($(this).index()==index)
          {
          total += parseFloat($(this).find('.saisie').val())||0;
          }
      }
      );
      $('table tr td.totalCol:eq('+index+')').html(total);
     calculateSum();
      calculateRowSum();
  }
  function calculateRowSum()
  {
      $('table tr:has(td):not(:last)').each(function(){
         var sum = 0; $(this).find('td').each(function(){
            sum += parseFloat($(this).find('.saisie').val()) || 0;
          });
             $(this).find('td:last').html(sum);
      });
  }
  function calculateSum() {
      var sum = 0;
      $("td.totalCol").each(function() {
              sum += parseFloat($(this).html())||0;
      });
      $("#sum").html(sum.toFixed(2));
  }
  </code></pre>
  
  <p>for better overview see this <a href="http://jsfiddle.net/db5SX/10892/" rel="nofollow noreferrer">jsfiddle</a></p>
  
  <p>Now the problem that i faced is that can i change the <em>sum function</em> of the rows to <em>multiplication function</em>. I mean that quantity cell of each row should be multiplied with the price cell of that row instead of <em>addition function</em>.</p>
  
  <p>For example i have the first row which is <strong>Windows based PC</strong> and i want to multiply the price with quantity and the result should be shown in the front cell of each row and this function should repeat to the rest of the rows.</p>
  
  <p>For better understanding please use the <a href="http://jsfiddle.net/db5SX/10892/" rel="nofollow noreferrer">jsfiddle</a> provided.</p>