P
Paresh Shah
Hi Friends...
I have an query on how to capture onFocus event for all the input
controls without writing onFocus event in the <input> tag.
say my html form has 3 or 4 or 5 input text boxes, now I want to
capture onFocus event for all the text boxes without writing onFocus
code in <input> tag.
for example:
<form name="frm1">
<input type="text" name="t1">
<input type="text" name="t2">
<input type="text" name="t3">
</form>
now in above example whenever user shifts the focus to input 1 i.e. t1
box, then some action should be taken say alert message is displayed,
then when focus shifts to input 2 i.e. t2 box, then same action is
displayed & alert message is displayed. for this I dont want to write
code given below:
<form name="frm1">
<input type="text" name="t1" onFocus="alert('hi')">
<input type="text" name="t2" onFocus="alert('hi')">
<input type="text" name="t3" onFocus="alert('hi')">
</form>
If some body could help me.....
Thanks in Advance
Regards
Paresh Shah
I have an query on how to capture onFocus event for all the input
controls without writing onFocus event in the <input> tag.
say my html form has 3 or 4 or 5 input text boxes, now I want to
capture onFocus event for all the text boxes without writing onFocus
code in <input> tag.
for example:
<form name="frm1">
<input type="text" name="t1">
<input type="text" name="t2">
<input type="text" name="t3">
</form>
now in above example whenever user shifts the focus to input 1 i.e. t1
box, then some action should be taken say alert message is displayed,
then when focus shifts to input 2 i.e. t2 box, then same action is
displayed & alert message is displayed. for this I dont want to write
code given below:
<form name="frm1">
<input type="text" name="t1" onFocus="alert('hi')">
<input type="text" name="t2" onFocus="alert('hi')">
<input type="text" name="t3" onFocus="alert('hi')">
</form>
If some body could help me.....
Thanks in Advance
Regards
Paresh Shah