The calculation I was able to do with JavaScript, but the output of it has to be in percentage.
<script>
var mb = document.querySelector("input[name=medidab]");
mb.addEventListener("keyup", calcImc, false);
function calcImc(){
var md_val = parseFloat(mb.value);
medidab = (md_val/50*100).toFixed(1);
if(!isNaN(medidab)){
document.querySelector("input[name=circunferenciabraco]").value = medidab;
}
}
</script>
And here and the form, I put the value in one field and the value of the calculation already comes out in the other one. It just has to come out in percentage and I do not know if it's possible.
<div>
<input class="campo-form-c" type="text" name="medidab" placeholder="Medida do Braço" maxlength="5">
</div>
<div>
<input class="campo-form-c" type="text" name="circunferenciabraco" placeholder="Circunferência do Braço" maxlength="5"></br>
</div>