0
I have this button, but when I click this it displays the value, not what is typed.
<input type="text" id = "numero"/>
<input type="submit" id = "adivinhar" value = "Clique aqui"/>
<script>
var AcessarElemento = document.getElementById("adivinhar");
AcessarElemento.onclick = botaoClicado;
function botaoClicado() {
alert(AcessarElemento.value);
};
</script>