DOM对象的继承关系

版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
本文链接: https://blog.csdn.net/qq_45683093/article/details/101566219
<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>DOM对象的继承关系</title>
	</head>
	<body>
		<div id="test"></div>
		<script>
			var test=document.getElementById('test');
			document.write(test+'<br>');
			document.write(test.__proto__+'<br>');
			document.write(test.nodeName+'<br>');
			document.write(test.tagName+'<br>');
			document.write(document.nodeName+'<br>');
			document.write(document.tagName);
		</script>
	</body>
</html>

猜你喜欢

转载自blog.csdn.net/qq_45683093/article/details/101566219
今日推荐