Contact: aviboots(AT)netvision.net.il
41,157 questions
53,647 answers
573 users
<input type="button" value="text" id="btnid" />
const btn = document.getElementById("btnid"); btn.addEventListener("click", ()=>{ if (btn.value === "text") { btn.value = "new text"; } else { btn.value= "text"; } }) /* run: */