Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

127
Views
Presionar la tecla Z para redirigir no funciona
 <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script> <script> var keyPressed = event.originalEvent.code; if(keyPressed == 'KeyZ'){ location.replace("https://classroom.google.com"); } </script>

Al hacer clic en la tecla Z, no sucede nada, sin embargo, cuando lo pruebo en un proyecto diferente. El enlace es avackgames.xyz

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

En este caso, debe usar el detector de eventos 'keydown'.

Para obtener más información, visite este sitio web.... ( Haga clic aquí )

Este es el código JavaScript que debe agregar a su código de archivo HTML. Espero que sea claro y útil, ¡Gracias!.

 <script> //Create event listener for 'keydown' window.addEventListener('keydown', KeyPressed) //Create a function with 'event' parameter function KeyPressed(event) { //Checking if Z key pressed, For your information, the code '90' is for the Z key. if (event.keyCode == 90) { //To be sure that the 'Z' key was pressed, let's show an alert message. alert('Yeeess, you clicked Z key!') } } </script>

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!