Hyperlinks

Description

Hyperlinks provide the basis for HTML by which users can navigate through content, both within the same document and across pages.

You create hyperlinks using the a element.

Attribute

The a element has local attributes:href, hreflang, media, rel, target, type.

  • href - Specifies the URL of the resource that the a element refers to.
  • hreflang - Specifies the language of the linked resource.
  • media - Specifies the device that the linked content is intended for. This attribute uses the same device and feature values with head meta element.
  • rel - Specifies the kind of relationship between the document and the linked resource. This attribute uses the same values as the rel attribute of the link element.
  • target - Specifies the browsing context in which the linked resource should be opened.
  • type - Specifies the MIME type of the linked resource, such as text/html.

The id, coords, shape, urn, charset, methods, and rev attributes are obsolete.





















Home »
  HTML CSS »
    HTML »




HTML Introduction
HTML Document
HTML Section
HTML Group Content
HTML Text Marker
HTML Table
HTML Form
HTML Embed