How to check the division by zero through isFinite?
<input type="button" value=" × " onclick="calculator.answer.value += '*';checkLength(this);" function div(value) { calculator.answer.value += '/'; if (!isFinite(calculator.answer.value)) { alert("Divide by zero error"); } }
alert(calculator.answer.value)for debugging before checking and see what goes into the isFinite function - newman