...

View Full Version : OnFocus not working in IE7



Philip M
12-06-2006, 09:11 AM
I have an order form which includes

<tr>
<td align="right"><font face="Arial" size="3"><em><b>Card
Number </b></em></td>
<td><input type="text" size="30" name="CardNumber" onFocus="doCCStuff(this)"></font><font face="Arial" size="2"> </font></td>
</tr>

The function doCCStuff calls up a prompt box for the user to enter his credit card number, which is then validated (Luhn test). If OK the card number is then written back into the textbox.

This has worked without problems for many years in all browsers (as far as I know). But recently two customers have reported that the prompt box does not appear when they tab to that field. They are entering their card numbers directly into the textbox which means that the numbers are not being validated (if not valid are rejected by the Perl script but that is not convenient). It seem that they are both using IE 7 - yet other users with IE7 have experienced no problems.

Any clues as to why the script doCCStuff() is not being triggered by onFocus? I should say that the users do not have JavaScript disabled as other parts of the form using JS work perfectly, nor are they geeks who can disable particular functions or whatever.

Is this an IE7 bug - I am told that early or beta releases had a number of "issues". And the final version has only just been released.

brandonH
12-06-2006, 02:51 PM
i had experienced similar problems when i was running earlier versions of IE7. they no longer happen with the latest release.

Philip M
12-06-2006, 06:50 PM
brandonH - thank you very much for that! So no need to panic! :D



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum