tabindex - HTML CSS HTML Global Attribute

HTML CSS examples for HTML Global Attribute:tabindex

Introduction

The tabindex attribute can control the order in which the Tab key moves through the HTML page, overriding the default order.

The following code demonstrates how to use this attribute.

Demo Code

ResultView the demo in separate window

<!DOCTYPE HTML>  
<html>  
    <head>      
        <title>Example</title>  
    </head>  
    <body>  
        <form>  
            <label>Name: <input type="text" name="name" tabindex="1"/></label>  
            <p/>  
            <label>City: <input type="text" name="city" tabindex="-1"/></label>  
            </p>  
            <label>Country: <input type="text" name="country" tabindex="2"/></label>  
            </p>  
            <input type="submit" tabindex="3"/>  
        </form>  
    </body>  
</html>  <!--  w ww.  ja  v  a2  s. c  om-->

Related Tutorials