Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

123
Visualizações
Demonstrate object key value according to input

I am trying to link my js vanilla code with json. I want to show value of object key that input in the search box. I add an example image of what i want. Thanks image of result type that i want

My basic html and script:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Sono brillo</title>
</head>
<body>
    <h1>hello</h1>
    <input id = "userInput" > <br> <br>
   <button onclick="myFunction()" > Run </button>
   <h1 id="message"> </h1>

   <style>
       body{background-color: darkblue; text-align: center; color: floralwhite;}

   </style>
   <script>
        function myFunction() {

            let userInput = document.querySelector("#userInput");
            let message = document.querySelector("#message");

            message.innerHTML = userInput.value;
}

   </script>
</body>
</html> 

and my json

https://drive.google.com/file/d/1ELIw__G5fXP3OZVTd-AZ9tu7YjzL-2G9/view?usp=sharing

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda