HTML DOM disabled ÊôÐÔ
¶¨ÒåºÍÓ÷¨
id ÊôÐÔÉèÖûò·µ»ØÎı¾ÓòµÄ id¡£
Óï·¨
textObject.id=id
ʵÀý
±¾ÀýÉèÖÃÁ˸ÃÎı¾ÓòµÄ id£º
<html>
<body>
<form>
<input type="text" id="text1" />
</form>
<p>The id of the text field is:
<script type="text/javascript">
x=document.getElementById('text1');
document.write(x.id
);
</script></p>
</body>
</html>