<legend>Information</legend>
<div class="row">
<div class="col-xs-12 col-sm-3 col-md-3">
<label><strong>{{$val}}</strong></label>
</div>
<script>
var str = "Hello world!";
var res = str.substring(0, 2);
if (res == ee) {
alert("Hello! I am an alert box!");
} else if (res == he) {
document.getElementById("checkbox").checked = true;
}
</script>
<div class="col-xs-12 col-sm-3 col-md-3">
<input type="checkbox" name="operator" id="checkbox" >
</div>
<div class="col-xs-12 col-sm-3 col-md-3">
<input type="checkbox" name="operator" id="checkbox">
</div>
<div class="col-xs-12 col-sm-3 col-md-3">
<input type="checkbox" name="operator" id="checkbox">
</div>
</div>
<br/>
i have included my html piece of code above. i don't know why check box is not responding for this piece of JavaScript. note: i should use JavaScript in the position between div's