NZL
11-04-2003, 05:30 PM
Hi,
i'm trying to figure out how you determine what item is currently in focus. So for example if there are two input boxes like so:
<input type=text name=input1>
<input type=text name=input2>
And a user clicks on input1 then i can check focus with something like
if (current.focus = input1) then
alert 'current focus is input1'
Is this possible? I should make it clear that i DON'T want an event such as onClick or onFocus to do this, I just want to be able to tell what element currently has focus at any time.
Does this make sense?
Thanks heaps.
:)
i'm trying to figure out how you determine what item is currently in focus. So for example if there are two input boxes like so:
<input type=text name=input1>
<input type=text name=input2>
And a user clicks on input1 then i can check focus with something like
if (current.focus = input1) then
alert 'current focus is input1'
Is this possible? I should make it clear that i DON'T want an event such as onClick or onFocus to do this, I just want to be able to tell what element currently has focus at any time.
Does this make sense?
Thanks heaps.
:)