var demo = document.getElementsByClassName("wx-button primary J_btnSubmitOrder J_ClickTrace"); function func() { demo[0].click(); } var interval = setInterval(func,1000); clearInterval(interval);