Forums Register Login
Checkbox issue
My jsp page has 5 checkboxes and a submit button which performs an action and loads the same jsp pasge again. Issue is that after checking(say 3 checkboxes) and submitting the form the checkboxes remain checked. How do I clecr the checkboxes after submitting the form?
This sounds strange to me, since once the page refreshes, the checkboxes should return to their original state, unless of course your code directs them otherwise.

Anyhow, you can check and uncheck any checkbox via javascript by accessing the checked attribute. The checked attribute can assume a value of true or false.


The above code will uncheck the checkbox whose id = "checkBox1".
[ May 26, 2004: Message edited by: Jeffrey Hunter ]
Moving to the HTML/Javascript forum.
Wink, wink, nudge, nudge, say no more ... https://richsoil.com/cards

This thread has been viewed 1028 times.

All times above are in ranch (not your local) time.
The current ranch time is
Jan 18, 2018 21:02:46.