This is a small excerpt of a larger script, but it is creating alot of
frustration. I am trying to query the vaule of a hidden form field via
onSubmit... if the function gets called out-right it works okay, but if it
gets called onSubmit, only the first form field value gets displayed and the
rest are undefined.
Help!
<script>
function showValues() {
document.write( document.projec t.number.value+ "<br>");
document.write( document.projec t.createdOn.val ue+"<br>");
document.write( document.projec t.closedOn.valu e+"<br>");
}
</script>
<form method="POST" name="project" onSubmit="showV alues();">
<input type="hidden" name="number" value="2004000" >
<input type="hidden" name="createdOn " value="yesterda y">
<input type="hidden" name="closedOn" value="tomorrow ">
<input type="submit">
</form>
<script>showVal ues();</script>