Posted by Stefan Mueller on 02/22/06 22:44
>> This html code should demonstrate my problems with 'tabindex':
>> <img src= 'pic23.gif' tabindex = '0'>
>> <input type = 'text'>
>> <p>
>> <img src= 'pic12.gif' tabindex = '0'>
>> <input type = 'text'>
>> <p>
>> <img src= 'pic25.gif' tabindex = '0'>
>> <input type = 'text'>
>
> Why are you placing the tabindex attribute on the image and not on the
> form input?
If I set the tabindex attribute on the form input like
<img src= 'my_pic.gif'>
<input type = 'text' tabindex = '0'>
<p>
<img src= 'my_pic.gif'>
<input type = 'text' tabindex = '0'>
<p>
<img src= 'my_pic.gif'>
<input type = 'text' tabindex = '0'>
then the images never gets the focus if you press the 'Tab' key.
> Assuming that you do/will assign an id to each image, then in theory:
> document.getElementById(imageId).focus()
Yes, but I don't know the imageId of the first image because the rows get
sorted before the focus has to be set to the first image. Is there a way to
figure that the imageId of the first picture?
Stefan
[Back to original message]
|