欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

html的DOM中document對(duì)象anchors集合用法實(shí)例

 更新時(shí)間:2015年01月21日 10:18:23   投稿:shichen2014  
這篇文章主要介紹了html的DOM中document對(duì)象anchors集合用法,實(shí)例分析了anchors集合的功能及使用技巧,需要的朋友可以參考下

本文實(shí)例講述了html的DOM中document對(duì)象anchors集合用法。分享給大家供大家參考。具體分析如下:

anchors 集合可返回對(duì)文檔中所有 Anchor 對(duì)象的引用。

語法:

復(fù)制代碼 代碼如下:
document.anchors[]

例子:
復(fù)制代碼 代碼如下:
<html> 
 
<body> 
<a name="first">First anchor</a><br /> 
<a name="second">Second anchor</a><br /> 
<a name="third">Third anchor</a><br /> 
<br /> 
 
Number of anchors in this document: 
<script type="text/javascript"> 
document.write(document.anchors.length) 
</script> 
</body> 
 
</html>

希望本文所述對(duì)大家的javascript程序設(shè)計(jì)有所幫助。

相關(guān)文章

最新評(píng)論