I would like to change the value of input fields in a form based on the input of one of the fields live without refresh before submitting the form.
For example
<input type="text" name="chance" value="50">
Let's say a user inputs 80 into the field.
Would I then be able to do the calculation 1/input x 98 where the input = 80 (so it would be 1/80 x 98).
I would then set this as the value of input of another field in the form.
<input type="text" name="payout" value="1/input x 98">
Without refreshing the page. TIA
Text to change
` . Also, what about limiting number of decimal places? – Semger Jun 23 '15 at 17:12