Link relation
HTML |
---|
Comparisons |
A link relation is a descriptive attribute attached to a hyperlink in order to define the type of the link, or the relationship between the source and destination resources. The attribute can be used by automated systems, or can be presented to a user in a different way.
In
CSS,
<link rel="stylesheet" href="example.css" />
, which indicates that the external resource linked to with the href attribute is a stylesheet, so a web browser will generally fetch this file to render the page. Another example is rel="shortcut icon" for the popular favicon icon.[1][2]Link relations are used in some
REST
system.
The Internet Engineering Task Force (IETF) has a registry of standardized link relations,[3] and a procedure for extending it defined in RFC 5988. HTML5 also defines valid link relations.[4]
In HTML4, the rev attribute of a link is also defined, which defines the reversed relationship between the resources. The attribute is removed in HTML5.
Semantic Web implementation
The
RDF triples, contributing to the automatic processability of machine-readable statements of the Giant Global Graph on the Semantic Web. The typed links in RDF are expressed as the value of the
terms or definitions from LOD datasets such as
rdf:type
property, defining the relationship type using well-established controlled vocabulary<rdf:type rdf:resource="http://schema.org/Person" />
References
- ^ Dubost, Karl (October 2005). "Web site meta data profile: favicon, …". World Wide Web Consortium. Retrieved 23 February 2011.
- ^ Dubost, Karl (24 October 2005). "How to Add a Favicon to your Site". World Wide Web Consortium. Retrieved 25 February 2011.
- ^ IANA link relations registry
- ^ HTML Living Standard; 4.12.4 Link types Web Hypertext Application Technology Working Group
External links
- rel values defined in HTML 4
- rel values to be defined in HTML5
- rel values which are defined in some specification
- WHATWG blog entry on link relations