当前位置: 首页 > 网络学院 > 客户端脚本教程 > HTML DOM > HTML DOM type属性
The type property sets or returns the MIME type for the linked resource.
type属性可设置或返回被链资源的MIME类型
anchorObject.type=type |
The following example returns the MIME type for the linked resource:
举例中将返回被链资源的MIME类型:
<html> <body> <p><a id="myAnchor" type="text/html" href="http://www.ruanchen.com">ruanchen.com</a></p> <script type="text/javascript"> x=document.getElementById("myAnchor"); document.write(x.type); </script> </body> </html> |
Get the MIME type of the link
得到连接的MIME类型