Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

206
Vistas
Is it possible to submit a form by triggering Enter with only javascript?

There ist a Form and Input without a button. You can send a message by typing Enter. The Form has an id.

Is it possible to trigger or kinda faking the Enter-Key only with JavaScript? (No jQuery, because the Page has already been loaded).

I tried:

e = jQuery.Event("keypress");
e.which = 13; //choose the one you want
document.querySelector("gui.frm_chat.tabs.tab_6.text.input#main").keypress().trigger(e);

But it didn't have jQuery.

enter image description here

about 4 years ago · Juan Pablo Isaza
2 Respuestas
Responde la pregunta

0

I think form.submit() is what you are looking for: https://www.w3schools.com/jsref/met_form_submit.asp

about 4 years ago · Juan Pablo Isaza Denunciar

0

I guess the better solution is form.requestSubmit(): https://developer.mozilla.org/en-US/docs/Web/API/HTMLFormElement/requestSubmit

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda