
要正在 JavaScript 外搜刮链接的 type 属性值,请利用 type 属性。你否以测验考试运转下列代码来猎取type属性的值。
事例
<!DOCTYPE html>
<html>
<body>
<p><a id = "qriesid" href = "https://qries.com/" type="text/html" >Qries</a></p>
<script>
var x = document.getElementById("qriesid").type;
document.write("Value of the type attribute: "+x);
</script>
</body>
</html>登录后复造
以上即是若是正在JavaScript外搜刮链接的type属性的值?的具体形式,更多请存眷萤水红IT仄台另外相闭文章!

发表评论 取消回复