| item() | ใช้ในการอ้างถึง node ที่เป็น array |
|---|
method:item ( index );
return type:node
content:ใช้ในการอ้างถึง node ที่เป็น array
example:var tagDivs = document.getElementsByTagName ( "div" ); for ( var i=0; i<tagDivs.length; i++ ) { alert ( tagDivs.item(i).className ); }
comment:เหมือนกับการใช้คำสั่ง tagDivs[i].className