How to add select all function in JSP for example date from and to?
<pre><code>&lt;body&gt;
&lt;hr&gt;
&lt;h1&gt;Click All or Search by Core ID&lt;/h1&gt;
&lt;form action = "call.jsp" onsubmit="return generateReport()" &gt;
&lt;label&gt;&lt;input type="checkbox" /&gt; ALL&lt;/label&gt;&lt;p&gt;Core ID : &lt;input type= "text" name = "core" value = ""/&gt;&lt;/p&gt;
&lt;h1&gt;Search by refresh Date From and To&lt;/h1&gt;
&lt;p&gt;Date From: &lt;input type="text" id="datepicker" name = "datef" value = ""&gt;&lt;/p&gt;
&lt;p&gt;Date To  : &lt;input type="text" id="datepicker1" name = "datet" value = ""&gt;&lt;/p&gt;
&lt;h1&gt;All Department except&lt;/h1&gt;
&lt;p&gt;Department Code : &lt;input type="text" name = "DepartM" value = ""&gt;&lt;/p&gt;
&lt;input type="submit" value="Search"/&gt;
&lt;/form&gt;
&lt;/body&gt;
</code></pre>

<p>Above are the code for jsp and I want the checkbox once click it will select all id and date from and to and below are my jasper report query</p>

<pre><code> SELECT
 CI_ID,
 Status,
 "status-Reason",
 CI_name,
 Serial_num,
 Manufacturer,
 model,
 receipT_date,
 refresh,
 core_id,
 departm
FROM
 `laptop` laptop
WHERE
 Core_id = $P{core}
 or refresh &gt;= $P{datef}
 and refresh &lt;= $P{datet}
 and departm &lt;&gt; $P{DepartM}
</code></pre>

<p>How can I use the checkbox as the select all function? Meaning to say once the user click the checkbox mean the user want to view all record (all id and from and to date etc). </p>