Closed
Bug 67418
Opened 24 years ago
Closed 24 years ago
focus method of a text field does not work from within onBlur event
Categories
(Core :: XUL, defect)
Tracking
()
People
(Reporter: mlw, Assigned: saari)
Details
Attachments
(1 file)
(deleted),
text/html
|
Details |
In the code example below, the user should not be able to leave the
left hand text field until at least one character has been entered.
The line which sets the focus back to text1 does not seem to work.
The status bar does show "In validate()", however suggesting that the validate
function is indeed being called. This is reproducable every time for me under
NT4 SP6 and Mozilla/5.0 (Windows; U; WinNT4.0; en-US; m18) Gecko/20010201
<HTML>
<BODY>
<form name=testForm method=post>
<input type=text name=text1 onBlur='validate();'>
<input type=text name=text2>
<script language="JavaScript" type="text/javascript">
function validate()
{
if (document.testForm.text1.value == "")
{
window.status = "In validate()";
document.testForm.text1.focus();
}
}
</script>
</form>
</BODY>
</HTML>
Comment 2•24 years ago
|
||
this is some evil javascript!! over to XPToolkits/widgets reassigning to saari.
Assignee: rogerl → saari
Component: Javascript Engine → XP Toolkit/Widgets
Comment 5•24 years ago
|
||
Yeah. (And more a joki thing anyways...)
*** This bug has been marked as a duplicate of 65581 ***
Status: UNCONFIRMED → RESOLVED
Closed: 24 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•