Forum Moderators: coopster
Now the Javascript function is like this
function moveNextField( fromField, number, toField ){
if( fromField.length > (number-1) ){
toField.focus();
}
}
the toField.focus() isn't the problem, cause I //comment it out, and it still gives the error
and the resulting code on the page from the php echos are like this:
<input type="hidden" name="OPNyear" value="20037">2003-7<input type="text" name="OPNnumber" id="OPNnumber" size="5" maxlength="5" onkeypress= "moveNextField( OPNnumber, 5, OPNnumber2)" >-<input type="text" id="OPNnumber2" name="OPNnumber2" size="1" maxlength="1" >
It says, error on line XX
Expecting an object.
Basically the line XX is right at the starting of the <?php tag, so I'm guessing since it's a IE error, then it would have to be an error in the actual tags, and not the php part. I know it's printing exactly what it should be from the php echos(see the previous post for what it does print in the "view source" of the page)