title: jQuery error "cannot read property 'call' of undefined"
body: <p>I'm a Java programmer trying to write a little javaScript. Bear with me. </p>
  
  <p>I would like a function that updates a total when a digit is entered in any one of the input fields in a table. I have the following line in <code>$(document).ready(function() { ... }</code></p>
  
  <pre><code>$("#lineCountTable").find('input').each().bind('keyup', function() { 
      updateTotal(this); 
  });
  </code></pre>
  
  <p>In Chrome's debug screen, I get:</p>
  
  <blockquote>
    <p>Uncaught TypeError: cannot read property 'call' of undefined". The line number pointed to is jQuery-1.8.2.js:611.</p>
  </blockquote>
  
  <p>I figure I have a syntax error in defining the function to be called. The <code>updateTotal(inputVar)</code> function is duly defined later in the JS file; in case someone's interested, it is:</p>
  
  <pre><code>function updateTotal(inputVar) {
      var row = inputVar.closest('tr');
      var lineCharge = row.find("dlsRowCharge").html().trim();
      var total = 0.0
      var lineCount = inputVar.val();
      if (isNumeric(lineCount)) {
          total = math.abs(lineCount * lineCharge).toFixed(2);
          row.children(".dlsRowTotal").html("$ " + total);
      }
  }
  </code></pre>
  
  <p>I know these functions are usually put inline; I would rather define them separately and call them, unless that's impossible.</p>