Sir,
Need your help, on toggle button need to show/hide DIV
Toggle button
<tr>
<td>GST / Non-Gst</td>
<td colspan="3">
<%--<label class="fancy-checkbox-toggle">
<input type="checkbox" id="chkTest" value="1" name="chkGST" />
</label>--%>
<label class="switch">
<input type="checkbox" onclick="toggle(this)" runat="server" id="chkTest" />
<span class="slider round"></span>
</label>
</td>
</tr>
Div
<div runat="server" style="display:none;" id="cont">
<table class="table table-bordered">
<tr>
<td>ID</td>
<td colspan="3">
<asp:TextBox ID="TextBox1" runat="server" Width="100px" Enabled="true" ></asp:TextBox>
</td>
</tr>
</table>
</div>
JavaScript
<script>
function toggle(ele) {
var cont = document.getElementById('cont');
if (cont.style.display == 'block') {
cont.style.display = 'none';
// document.getElementById(ele.id).value = 'Show DIV';
}
else {
cont.style.display = 'block';
// document.getElementById(ele.id).value = 'Hide DIV';
}
}
</script>