I'm trying to default a value of a text field to 0, if the user does not submit anything. Does the following code illustrate this or have I got it all wrong?
function checkValue() {
var defaultValue;
defaultValue = 0;
if ((document.getElementById("otherFees").value)=="")
(document.getElementById("otherFees"))=defaultValue;
}