what i need is, When i click on button "Click", the Column "Delete" Should be visible and editable. and when i click on the same button "click" again, the delete column should slide right and hide behind the Column B, C and D and so on, without damaging the width of the complete table and view. Check it here.
JSfiddle Demo
<div class="menuBtn">click</div>
<table class="whole" border="1px">
<tr>
<th class="menu">Delete</th>
<th>Data1 c</th>
<th>date2 c</th>
</tr>
<tr>
<td class="menu">
<input type="checkbox" value="Bike">
</td>
<td>data</td>
<td>date1</td>
</tr>
<tr>
<td class="menu">
<input type="checkbox" value="car">
</td>
<td>data2</td>
<td>date3</td>
</tr>
</table>
JS
$('.menuBtn').click(function (event) {
value = $('.whole').css('right') === '-100px' ? 0 : '-100px';
$('.whole').animate({
right: value
});
});
CSS:
.whole {
position: relative;
Width:100%;
}
.menu {
left: 0;
}