Horje
What is HTML tabindex Attribute

Definition and Usage

The tabindex attribute specifies the tab order of an element (when the "tab" button is used for navigating).

The tabindex attribute can be used on any HTML element (it will validate on any HTML element. However, it is not necessarily useful).


Browser Support

Syntax

<element tabindex="number">

Attribute Values

Value Description
number Specifies the tabbing order of the element (1 is first)

How to add Links with a specified tab order

Note: Try navigating the elements by using the "Tab" button on your keyboard.
index.html
Example: HTML
<!DOCTYPE html>
<html>
<body>

<div tabindex="1">Horje</div><br>
<div tabindex="3">Google</div><br>
<div tabindex="2">Microsoft</div>

<script>
// At start, set focus on the first div
document.getElementsByTagName('div')[0].focus();
</script>

<p tabindex="4"><b>Note:</b> Try navigating the elements by using the "Tab" button on your keyboard.</p>

</body>
</html>

Output should be:

How to add Links with a specified tab order




html tabindex attribute

Related Articles
What is HTML accesskey Attribute HTML Global Attributes
What is HTML class Attribute HTML Global Attributes
What is HTML contenteditable Attribute HTML Global Attributes
What is HTML data-* Attributes HTML Global Attributes
What is HTML dir Attribute HTML Global Attributes
What is HTML draggable Attribute HTML Global Attributes
What is HTML enterkeyhint Attribute HTML Global Attributes
What is HTML hidden Attribute HTML Global Attributes
What is HTML id Attribute HTML Global Attributes
What is HTML inert Attribute HTML Global Attributes
What is HTML inputmode Attribute HTML Global Attributes
What is HTML lang Attribute HTML Global Attributes
What is HTML popover Attribute HTML Global Attributes
What is HTML spellcheck Attribute HTML Global Attributes
What is HTML style Attribute HTML Global Attributes
What is HTML tabindex Attribute HTML Global Attributes
What is HTML title Attribute HTML Global Attributes
What is HTML translate Attribute HTML Global Attributes
What are the HTML Global Attributes HTML Global Attributes

Single Articles
How to add Links with a specified tab orderHTML Global Attributes

Read Full:
HTML Global Attributes
Type:
Develop
Category:
Web Tutorial
Sub Category:
HTML Global Attributes
Uploaded by:
Admin
Views:
28


Reffered: https://www.w3schools.com/tags/att_global_tabindex.asp