I use a radio buton 'plata' with two values '1' and '2' in my form and another input hidden 'plata2' take one value depend to 'plata'.
So i use this code inside in an existant function total():
test = document.getElementById('plata').value;
if (test == 1) {document.getElementById('plata2').value=pretfinal;}
else {document.getElementById('plata2').value=avansfinal;}
but 'plata2' take just first value, 'else' never works? can help with this. THX
Aucun commentaire:
Enregistrer un commentaire