Bug 18706
Summary: | onblur is called twice | ||
---|---|---|---|
Product: | WebKit | Reporter: | Greg Hulands <ghulands> |
Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED FIXED | ||
Severity: | Normal | CC: | barraclough, cecotto196 |
Priority: | P2 | ||
Version: | 525.x (Safari 3.1) | ||
Hardware: | Mac | ||
OS: | OS X 10.5 |
Greg Hulands
<html>
<head>
</head>
<body>
<form>
<script>
function validate(field, regex, error) {
if (field.value.match(regex) == null) {
alert(error);
field.focus();
}
}
</script>
<input onBlur="validate(this, new RegExp('^\\d{8}$'), 'ID must be 8 digits long.');" type="text" name="19.3.0.1.0.0.1.1.1.3" />
<input type="text"/>
</form>
</body>
</html>
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Steffen Otto Jensen
I have the exact same problem.
Safari: Version 5.0.3 (6533.19.4)
However with Chrome: 8.0.552.231
The event does only fire once, as I think it should.
My code is different, but in essence it does the same thing.
I hope this will be fixed, or someone has a work around for this.
Steffen Otto Jensen
I just downloaded the nightly build, for both Mac and Windows:
Mac: Version 5.0.3 (6533.19.4, r75294)
* This fixed the problem
Windows: 5.0.3 (7533.19.4)
* This fixed the problem
Thanks.