How can I make an accordion in plain HTML?
- <table border="1">
<tr>
<th><input name="checkbox" type="checkbox" id="selectall"/></th>
<th>Multipal Row </th>
<th>Rating</th>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="1"/></td>
<td>First Chek </td>
<td>1</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="2"/></td>
<td>Second Chek </td>
<td>2</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="3"/></td>
<td>Third Chek </td>
<td>3</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="4"/></td>
<td>Fourth Chek </td>
<td>4</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="5"/></td>
<td>Five Chek </td>
<td>5</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="6"/></td>
<td>Six Chek </td>
<td>6</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="7"/></td>
<td>Seven Chek </td>
<td>7</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="8"/></td>
<td>Eight Chek </td>
<td>8</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="9"/></td>
<td>Nine Chek </td>
<td>9</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="10"/></td>
<td>Ten Chek </td>
<td>10</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="11"/></td>
<td>Elevan Chek </td>
<td>11</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="12"/></td>
<td>Twel Chek </td>
<td>12</td>
</tr>
<tr>
<td align="center"><input type="checkbox" class="case" name="case" value="13"/></td>
<td>Thirty Chek </td>
<td>13</td>
</tr> </table>
If you don't like jQuery, check out Uranium - you don't need to use any javascript and can just add some attributes to your HTML.
Try this
http://csswizardry.com/2011/02/pure-css3-accordion/
I would recommend the following tutorial : https://codepen.io/abergin/pen/ihlDf?editors=1100#0 it does exactly what you want.
The HTML code :
And a heavier use of CSS :
I think you should have a look at jQuery UI.
http://docs.jquery.com/UI/Accordion
Accordion in only html here is the list of links:
1> http://media02.hongkiat.com/css-based-accordion/demo/index.html.
2>http://andornagy.com/pure-css-accordion/
3>http://tympanus.net/codrops/2012/02/21/accordion-with-css3/