SOLVED: JavaScript error .reset is not a function
Posted by: Run Tings Proper,
on 27 Jun 2011 |
View original | Bookmarked: 0 time(s)
Read this article if you are trying to call reset() on a <form> DOM element but you're getting an error stating .reset is not a function. PROBLEM I was working on some jquery UI code and I wanted to reset the form when the dialog was closed. I found a simple snippet explaining how to do this: $(this).find("form")[0].reset();
If you arent familiar with this notation the [0] gets the underlying DOM object rather than the jQuery object reset() is a built in JavaScript feature.
Other...