title: How to pass a reference of DOM object to jQuery function?
body: <p>I want to pass a reference of the DOM object to a jQuery function. However the function does not get a reference to the DOM object.  It does get a string containing the DOM object. So i get an error on the following example</p>
  
  <pre><code>&lt;input type="text" size="30" onchange="change_total_price(this)" id="priceField"&gt;
  </code></pre>
  
  <p>.</p>
  
  <pre><code>function change_total_price(input) {
      input.closest('div').find('#amountField').val());
  }
  </code></pre>