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

268
Visualizações
Click Next Button from Chrome Console Using Javascript

I am trying to click on button from Chrome console

<a class="toolTip ui-button ui-widget ui-state-default ui-corner-all ui-button-icon-only" href="#" role="button" aria-label="next page" data-hasqtip="211" oldtitle="next page" title="" aria-describedby="qtip-211">
<span class="ui-button-icon-primary ui-icon ui-icon-triangle-1-e"></span>
<span class="ui-button-text"></span></a>

enter image description here

i have tried

document.querySelector("#results > div.results_navigation.top_results_navigation.displayButtons > div.results_pager.ui-widget-content > div.arrow_container > a:nth-child(4)").Click(); 

But it does not work

about 4 years ago · Juan Pablo Isaza
2 Respostas
Responde à pergunta

0

Js functions are case sensitive and you are using Click instead of click. Also your html and js code not match. So...

//check if btn was clicked
document.querySelector(".next_page").onclick = function() {
  // indicate that btn was clicked
  this.innerText = 'clicked';
  // set back the text after half a second
  setTimeout(() => document.querySelector(".next_page").innerText = 'button', 500);
};

// click the button every second
setInterval(() => document.querySelector(".next_page").click(), 1000);
<a class="next_page" href="#" role="button" aria-label="next page" data-hasqtip="211" oldtitle="next page" title="" aria-describedby="qtip-211">
  <span class="ui-button-icon-primary ui-icon ui-icon-triangle-1-e"></span>
  <span class="ui-button-text">button</span></a>

about 4 years ago · Juan Pablo Isaza Relatório

0

If the click handlers are added by jQuery, often the native click() method on the HTMLElement will not trigger the jQuery handlers. You can use jQuery to trigger the click and it should trigger the handlers bound with jQuery.

$('#results > div.top_results_navigation > div.results_pager a[aria-label="next page"]').trigger('click'); // or .click() even
about 4 years ago · Juan Pablo Isaza Relatório
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