<html>
<body>
<p>单击该按钮以检查该按钮元素是否支持 Core XML DOM Level 2 功能。</p>
<button onclick="myFunction()">试一试</button>
<p><strong>注意:</strong>Chrome、Firefox、Opera 和 IE8 及更早版本不支持此方法。</p>
<p id="demo"></p>
<script>
function myFunction() {
var item = document.getElementsByTagName("BUTTON")[0];
var x = item.isSupported("Core", "2.0");
document.getElementById("demo").innerHTML = x;
}
</script>
</body>
</html>