HTML DOM tabIndex property
Definition and Usage
The tabIndex property sets or returns the tab order of a radio button.
Syntax
HTMLElementObject.tabIndex=
tabIndex
Browser support





All major browsers support the tabIndex property
Example
Example
Change the tab order of three links:
<!DOCTYPE html><html>
<head>
<meta charset="utf-8">
<title>Runoob Tutorial(runoob.com)
title
<
script
function changeTabIndex() { document.getElementById('1').tabIndex="3" document.getElementById('2').tabIndex="2" document.getElementById('3').tabIndex="1" }
script
head
<body>
<p>
<a id="1" href="https://www.runoob.com" 1 a p>
<p>
<a id="2" href="https://www.runoob.com" 2 a p>
<p>
<a id="3" href="https://www.runoob.com" 3 a p>
<input type="button" onclick="changeTabIndex()" value=">Change TabIndex
"
body
html
Try it »
Element object