Skip to content

Commit

Permalink
java_atividades
Browse files Browse the repository at this point in the history
  • Loading branch information
R7zx committed Jul 1, 2022
1 parent 36aa795 commit 1d4e396
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions attCadastro.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</head>

<body>
<input id="entrada" type="text" placeholder="Insira seu nome">
<input id="nome" type="text" placeholder="Insira seu nome">
<input id="idade" type="number" placeholder="Insira sua idade">
<br><br>
<hr>
Expand All @@ -28,7 +28,7 @@
document.getElementById("salvar").addEventListener("click", function () {

let objeto = {
entrada: document.getElementById("entrada").value,
nome: document.getElementById("nome").value,
idade: document.getElementById("idade").value,

};
Expand All @@ -43,12 +43,13 @@

for (let index = 0; index < array.length; index++) {
let element = array[index];
console.log(array[index].entrada);
console.log(array[index].nome);
console.log(array[index].idade);


if (array[index].nome == 'raysson') {
document.getElementById("p").innerText = array[index].idade;
document.getElementById("p").innerText = array[index].nome;

}
}
console.log(array);
Expand Down

0 comments on commit 1d4e396

Please sign in to comment.