title: Can we call a java function from the html text-box?
body: <p>I'm doing a web project using jsp,mysql,ajax using netbeans and mysql.
  I'm having 3 textboxes, 2 is for taking the input from the user. The 3rd textbox should show the product of 2 input values.</p>
  
  <p>How to do this?
  Should i make a ajax call or can i call a java function in the 3 textbox.</p>
  
  <p>The code is </p>
  
  <pre><code>&lt;input type="text" value="" name="quantity"/&gt;
  &lt;/td&gt;&lt;td&gt;&lt;input type="text" value="" name="price"/&gt;
  &lt;/td&gt;&lt;td&gt;&lt;input type="text" value="" name="total"/&gt;
  </code></pre>
  
  <p>In the value attribute of the textbox named "total" can i call a java function?
  something like <code>value="getTotal()"</code>,but if i can how can i access the other two values.</p>
  
  <p>Otherwise should i make a ajax call?</p>