function
checkValue(){if (document.getElementById('valuation ').value >= 1000000){
if (confirm("This value is over $1,000,000. Are you sure you meant to enter such a large value?")){
}
else {
document.getElementById('valuation').focus();
}
return false;
}
}
I was able to set focus to any field, except the one I just came from. The only hack I was able to find was to set focus first to another field, then the field I came from and then use the follwing in my <input> statement.
onFocus="this.select()"
Here is the javascript function I had to use:
function
checkValuation(){if (document.getElementById('valuation').value >= 1000000){
if (confirm("This value is over $1,000,000. Are you sure you meant to enter such a large value?")){
}
else {
document.getElementById('otherfield').focus();
document.getElementById('valuation').focus();
}
return false;
}
}
David Mineer
No comments:
Post a Comment