当前位置: 首页 > 网络学院 > 客户端脚本教程 > HTML DOM > HTML DOM tabIndex属性

HTML DOM
DOM Input Checkbox
DOM Input File 对象
DOM Input Hidden对象
DOM Input Password 对象
DOM Input Radio 对象
DOM Input Reset 对象
DOM Input Submit 对象
DOM Input Text 对象
DOM Link 对象
DOM Location 对象
DOM Meta 对象
DOM Navigator 对象
DOM 对象
DOM Option 对象
DOM Screen 对象
DOM Select 对象
DOM Style 对象
DOM Table 对象
DOM TableData 对象
DOM TableHeader 对象

HTML DOM tabIndex属性


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-03-04   浏览: 441 ::
收藏到网摘: n/a

Definition and Usage
定义与用法

The tabIndex property sets or returns the tab order for an area in an image-map.
tabindex属性可设置或返回热点图片中的tab顺序。

Syntax
语法

areaObject.tabIndex=tabIndex


Example
举例

The following example shows the tab order of the areas in the image-map:
下面的举例将展示如何显示出热点图片area的tab顺序:

<html>
<head>
<script type="text/javascript">
function showTabIndex()
{
var sun=document.getElementById('sun').tabIndex;
var mercury=document.getElementById('mercury').tabIndex;
var venus=document.getElementById('venus').tabIndex;
document.write("Tab index of Sun: " + sun);
document.write("<br />");
document.write("Tab index of Mercury: " + mercury);
document.write("<br />");
document.write("Tab index of Venus: " + venus);
}
</script>
</head>
<body>
<img src ="planets.gif"
width="145" height="126"
alt="Planets"
usemap ="#planetmap" />
<map name="planetmap">
<area shape ="rect" coords ="0,0,82,126"
href ="sun.htm" id="sun" tabIndex="1" />
<area shape ="circle" coords ="90,58,3"
href ="mercur.htm" id="mercury" tabIndex="2" />
<area shape ="circle" coords ="124,58,8"
href ="venus.htm" id="venus" tabIndex="3" />
</map>
<input type="button" onclick="showTabIndex()"
value="Show tabIndex" />
</body>
</html>


演练

Return the tab orderof the areas in an image-map
返回热点地图中area的tab顺序

评论 (0) All

登陆 | 还没注册?