How to reset a list
<p>It might be a silly question but still i am facing problem with this.</p>

<pre><code>  var eformDetailIds = []; 


eformDetailIds=$("[name=eform_id]").map(function(){ return $(this).val() }).get();  
</code></pre>

<p>this is the code that i have written in js function and calling this function on button click.</p>

<p>But the problem is the list eformDetailIds containing the previous values also. could you please how to set this empty list for every function call? Thanks in advance.</p>
