I have a form in which I have kept two fields in a div. There is a check box that determines the visibility of this div MY code is not working.It is not allowing me to click on this
<script>
function yesnoCheck() {
if (document.getElementById('yesCheck').checked) {
document.getElementById('ifYes').style.visibility = 'visible';
}
else document.getElementById('ifYes').style.visibility = 'hidden';
}
</script>
<input type="CHECKBOX" onclick="javascript:yesnoCheck();" name="period" id="yesCheck">
<label for "period" style="padding-left:20px;margin:0px;color:black;font-weight:bold;">Time </label>
<div id="ifYes" style="visibility:hidden" >
<label style="padding:0px;margin:0px;color:black;font-weight:bold;">Date From </label>
<input style="padding:0px;margin:0px;" type="date" id="datefrom" name="datefrom"value="" placeholder="Date from" >
<label style="padding:0px;margin:0px;color:black;font-weight:bold;">To</label>
<input style="padding:0px;margin:0px;"type="date" id="dateto" name="dateto" value="" placeholder="Date to">
</div>