I make the calculation of these fields (Ingresso * Publico).
function calcular() {
var n1 = parseFloat(document.getElementById('valor_do_ingresso').value);
var n2 = parseInt(document.getElementById('publico_aproximado').value);
document.getElementById('renda_ingressos').innerHTML = n1 * n2;
}
I'm using onkeyup: calcular() within the extra attributes field in the Ingresso and Publico fields.
The field (Renda) should receive the result of the calculation of the (Ingresso and Publico).
As can be seen in the image, typing the values shows the result of the value, but this result is not shown inside the field, what could have happened?
function calcular() {
var n1 = parseFloat(document.getElementById('valor_do_ingresso').value);
var n2 = parseInt(document.getElementById('publico_aproximado').value);
document.getElementById('renda_ingressos').innerHTML = n1 * n2;
}
I'm using onkeyup: calcular() within the extra attributes field in the Ingresso and Publico fields.
The field (Renda) should receive the result of the calculation of the (Ingresso and Publico).
As can be seen in the image, typing the values shows the result of the value, but this result is not shown inside the field, what could have happened?