Hello Guys I have a textbox which if the value inside the textbox is zero. It will pop up alert. but no alert is happening.
<input type="text" id="numbers" value= "0" >
<th style="width:5%;"><h4><input id="submitbutton" onclick="clicked();" class="btn btn-success" type="submit" name="<?php if($final==true){ echo "viewsummary" ;}else{ echo "next";} ?>" value="<?php if($final==true){ echo "View Summary" ;}else{ echo "Submit";} ?>" class="subbtn"/>
<script language="javascript">
document.getElementById('submitbutton')
function clicked(){
if (document.getElementById('numbers') == 0) {
window.alert("Please Play the Audio First");
}
}
</script>
I dont know whats the error If I look at the code for me its just fine? whats wrong? Thank you guys :")