What is the use of profile attributes in the HTML <head>
tag?
I happened to read about it in here : http://www.w3schools.com/tags/tag_head.asp.
I could not understand this(http://www.w3.org/2002/12/namespace) either, since it is too technical (for me).
I have never used it. What is the purpose it serves?
The purpose of the HTML profile attribute is to specify the URI to a file or a white space separated list of URIs of meta data (i.e. information about the webpage).
Definition and Usage The <head> element is a container for metadata (data about data) and is placed between the <html> tag and the <body> tag. Metadata is data about the HTML document. Metadata is not displayed. Metadata typically define the document title, character set, styles, scripts, and other meta information.
HTML <head> tag When writing in HTML, the <head> tag is used to contain specific information about a web page, often referred to as metadata. This information includes things like the title of the document (which is mandatory), scripts or links to scripts, and CSS files.
The <head> tag in HTML is used to define the head portion of the document which contains information related to the document. The <head> tag contains other head elements such as <title>, <meta>, <link>, <style> <link> etc. In HTML 4.01 the <head> element was mandatory but in HTML5, the <head> element can be omitted.
The URI in the profile attribute points to a document containing information regarding metadata. Profiles defines properties that may be used by the HTML meta tag
and the HTML link tag
. There are no prescribed formats for profiles. The profile attribute is no longer supported in HTML 5.
HTML5
has dropped the profile attribute from the head
element (details).
You could however, use a rel
attribute to the links to achieve this.
So, instead of
<HEAD profile="http://www.acme.com/profiles/core">
it is now
<link rel="profile" href="http://gmpg.org/xfn/11" />
From W3,
The profile attribute of the HEAD specifies the location of a meta data profile. The value of the profile attribute is a URI. User agents may use this URI in two ways:
- As a globally unique name. User agents may be able to recognize the name (without actually retrieving the profile) and perform some activity based on known conventions for that profile. For instance, search engines could provide an interface for searching through catalogs of HTML documents, where these documents all use the same profile for representing catalog entries.
- As a link. User agents may dereference the URI and perform some activity based on the actual definitions within the profile (e.g., authorize the usage of the profile within the current HTML document). This specification does not define formats for profiles.
Simply put, XMDP introduced a simple way to define URLs and meanings used in an element, to read and write by both humans and machines as a dictionary of meta information. It was an initial attempt to achieve relations between elements.
To read more on this, find the references listed at the end of the answer.
IMO, things have really improved in the recent past to achieve semantic relations thanks to introduction and implementations of Rich Snippets, which allows multiple formats for implementing structured data.
More information is available at schema.org and FAQ.
Here is the list of supported markup formats
... More Details
With recent updates, there is also linking of author, and content published (Google+ only), by adding this :
<link href="https://plus.google.com/{+PageId}" rel="publisher" />
References / Further reading :
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With