jQuery: How to make a clear button?
问题 I have a search field, and I need a clear button. I currently have the button, but I don't know how to do it, I have 6 textfields, 2 comboboxes, and 2 multiple select lists How do I clear all of them in one clear function?? I know the HTML way, but I am using Grails and the type="reset" does not work. That's why I want a jQuery way of deleting textboxes' values, leaving the combobox in the first index, and clear all options from the multiple select list. Thanks for the help :D 回答1: You can