Hello to everyone,
I have a form where I need to SUM two form fields to the third field - automatically after filling the fields before SUBMIT.
I am trying with this code :
but it doesnt works.
could you help me?
thx
I have a form where I need to SUM two form fields to the third field - automatically after filling the fields before SUBMIT.
I am trying with this code :
<script>form fields has 'price' in class and resulting field has id 'nezalistovane_0_cena_celkem'
$('.price').keyup(function () {
var sum = 0;
$('.price').each(function() {
sum += Number($(this).val());
});
$('#nezalistovane_0_cena_celkem').val(sum);
});
</script>
but it doesnt works.
could you help me?
thx