Anchor Object
The type property sets or returns the value of the type attribute of a link.
The type attribute specifies the MIME type of the linked document.
Set the type property:
Return the type property:
| Value | Description |
|---|---|
| MIME-type | Specifies the MIME type of the linked document. Look at IANA MIME types for a complete list of standard MIME types. |
![]()
The type property is supported in all major browsers.
Return the value of the type attribute of a specific link:
The output of the code above will be:
Anchor Object
Your message has been sent to W3Schools.