Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Image swapping with tab key

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
I have an image that is being swapped with an onMouseOver command, but I would also like the image to swap when the image is focused on using the tab key. I have tried onFocus and onSelect, but neither seem to be applicable to an image input.

Anyone know of a way I can change the image src when a user highlights the image object using the tab key?
 
<input tabindex=&quot;3&quot; type=&quot;Image&quot; name=&quot;world&quot; width=&quot;42&quot; height=&quot;58&quot; src=&quot;virtuoso1.gif&quot; onmouseover=&quot;src = 'virtuoso2.gif'; return true;&quot; onmouseout=&quot;src= 'virtuoso1.gif'; return true;&quot; onclick=&quot;submit(this.form);&quot;>
 
Never mind...I just tried one last time since you said that, and this time it worked! Wouldn't ya know?

Anyway, thanks a bunch.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top