For a web project using JSP, MySQL, AJAX with Netbeans and MySQL, I have three textboxes. Two textboxes are for user input, and the third should display the product of the two input values.
How can I achieve this? Should I make an AJAX call or can I call a Java function in the third textbox?
The code is as follows:
<input type="text" value="" name="quantity"/>
</td><td><input type="text" value="" name="price"/>
</td><td><input type="text" value="" name="total"/>
In the value attribute of the textbox named "total", can I call a Java function like value="getTotal()"
? If so, how can I access the other two values?
Alternatively, should I make an AJAX call?