when fill Wrong details and click on submit button.Error accured fine but after that i click on reset button so textbox not clear why
button
"
"
javascript code for clear filds
"
"
when fill Wrong details and click on submit button.Error accured fine but after that i click on reset button so textbox not clear why
button
"
"
javascript code for clear filds
"
"
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Amit MohantyRank #112 · 20K reputationPosted May 10, 2024, 3:30 AM EDT
Check this
function clearForm() { event.preventDefault(); document.getElementById('User_Name').value = ""; document.getElementById('Password').value = ""; document.getElementById('Role').value = ""; }