Target Attribute

Overview The target attribute indicates how to open the document linked. It can be opened in the same window, same or a specific frame. Note: target is an optional attribute. If this option is not set, the links will open in the same window. Syntax & Example <a href=”example.html” target=”_self|_blank|_parent|_top”> For instance, if you are […]

Download Attribute

Overview The download attribute specifies that the target will be downloaded when a user clicks on the hyperlink. The value of the attribute will be used for the name of the downloaded file. There are no limitations on allowed values. File extension (.html, .png, .jpg, .pdf, .txt, etc.) will be automatically detected by the browser […]

Type Attribute

Overview A type attribute specifies the nature of a linked file or a document. Content types are case-insensitive. Note: type is an optional attribute. Syntax & Example <a href=”example.png” type=”file_type”> For instance, if you are going to link to a .PNG file, type attribute should read as follows <a href=”example.png” type=”image/png”> Content Type Examples Following are […]

Hreflang Attribute

Overview The hreflang attribute specifies linked document’s language. Note: hreflang is an optional attribute, however its use is advised. Syntax & Example <a href=”example.html” hreflang=”language_iso_code”> For instance, if you are going to link to a French document, hreflang attribute should read as follows <a href=”example.html” hreflang=”fr”> ISO Country Codes Language ISO Code Abkhazian ab Afar […]

A note to our visitors

This website has updated its privacy policy in compliance with changes to European Union data protection law, for all members globally. We’ve also updated our Privacy Policy to give you more information about your rights and responsibilities with respect to your privacy and personal information. Please read this to review the updates about which cookies we use and what information we collect on our site. By continuing to use this site, you are agreeing to our updated privacy policy.