View Single Post
Old March 24th, 2006, 10:07 PM   #2 (permalink)
H
after g, before i
Resident.
 
H's Avatar
 
Joined in Jul 2004
Lives in N,BC,CA
8,087 posts
Gave thanks: 48
Thanked 131 times
You should be able to do something like this in JavaScript to clear a form element.

Code:
document.getElementById('formElementID').value = '';
There's probably easier ways to do it to all form elements.. but I'd have to look it up.

If you want a button that clears or resets a form, you could just use :
Code:
<input type="reset" name="reset" value="reset" />
This resets a form to it's initial state on the page load.
H is offline   Reply With Quote