Disable tab key on a specific div

前端 未结 2 908
执念已碎
执念已碎 2021-02-07 19:26

I have the following structure:

Some content
Some content
2条回答
  •  青春惊慌失措
    2021-02-07 19:57

    @John Strickler is right. The behaviour of the tab key can be changed with the tabindex attribute. It is the order the elements will have the focus.

    With

    Some content
    you should prevent the focus to be on your div.

    More info here: http://www.htmlcodetutorial.com/forms/_INPUT_TABINDEX.html

提交回复
热议问题