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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

tabbing and the object tag 1

Status
Not open for further replies.

TheConeHead

Programmer
Aug 14, 2002
2,106
US
Is there a way to not have an object tag get selected when tabbing through? I am tabbing through the buttons on my page (see Section 508) and the tab is getting stuck on a flash .swf imported into the page via an object tag?

any ideas?
 
have you set the tabindex? _________________________________________________________
for the best results to your questions: FAQ333-2924
01001111 01101110 01110000 01101110 01110100
onpnt2.gif
[/sub]
 
I have not... I am not familiar with that... how does that work?
 
quick example
<input type=&quot;button value=&quot;one&quot; tabindex=&quot;1&quot;>
<input type=&quot;button value=&quot;one&quot; tabindex=&quot;5&quot;>
<input type=&quot;button value=&quot;one&quot; tabindex=&quot;4&quot;>
<input type=&quot;button value=&quot;one&quot; tabindex=&quot;3&quot;>
<input type=&quot;button value=&quot;one&quot; tabindex=&quot;6&quot;>
<input type=&quot;button value=&quot;one&quot; tabindex=&quot;2&quot;> _________________________________________________________
for the best results to your questions: FAQ333-2924
01001111 01101110 01110000 01101110 01110100
onpnt2.gif
[/sub]
 
but is there a way to disable something from being tabbed? it's not that I want it to be tabbed in a particular order- I do not want the object to be tabbed at all...

possible with tabindex?
 
quick fix would be to place this in the tag you do not want focus
onfocus=&quot;document.formname.differentbox.focus()&quot;>

this will give the other object focus onFocus _________________________________________________________
for the best results to your questions: FAQ333-2924
01001111 01101110 01110000 01101110 01110100
onpnt2.gif
[/sub]
 
I thought the -1 setting in tabindex would work also but wanted to double check my memory and after checking it does.
<input type=&quot;button&quot; value=&quot;one1&quot; tabindex=&quot;1&quot; onFocus=&quot;document.bgColor='green'&quot;>
<input type=&quot;button&quot; value=&quot;one2&quot; tabindex=&quot;5&quot; onFocus=&quot;document.bgColor='blue'&quot;>
<input type=&quot;button&quot; value=&quot;one3&quot; tabindex=&quot;-1&quot; onFocus=&quot;document.bgColor='red'&quot;>
<input type=&quot;button&quot; value=&quot;one4&quot; tabindex=&quot;3&quot; onFocus=&quot;document.bgColor='purple'&quot;>
<input type=&quot;button&quot; value=&quot;one5&quot; tabindex=&quot;6&quot; onFocus=&quot;document.bgColor='yellow'&quot;>
<input type=&quot;button&quot; value=&quot;one6&quot; tabindex=&quot;-1&quot; onFocus=&quot;document.bgColor='black'&quot;>

notice the screen does not change to the colors that have -1 as they never get focus _________________________________________________________
for the best results to your questions: FAQ333-2924
01001111 01101110 01110000 01101110 01110100
onpnt2.gif
[/sub]
 
hmmmm ok I see what you are saying... I guess I just need to figure out how to syntactically put that together... the item I would want it to go to would not be in a form.... I guess I could put it in a form if need be... but I am not sure if an object tag can handle onfocus....
 
beautiful!! I posted my last message before I saw your last... tabindex=-1 works!! thanks for the help!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top