Javascript – Form Resetting is not working using jquery

ajaxjavascriptjquery

I want to reset the form after calling an ajax function.
This is the code i gave in the jquery:

$("#frm_silder").reset();

Here frm_silder is the id of form. But when I'm using this code i got an eorror message like this.

$("#frm_silder").reset is not a function

In my html i give the id to form like this:

<form name="frm_silder" id="frm_silder" method="post">

So what is the problem in my code?

Best Solution

In jQuery

$('#frm_silder')[0].reset();

in Javascript

document.getElementById('frm_silder').reset()