Hypertext Markup  «Prev  Next»

Purpose of META Tags

META tags

META tags are empty tags used to record information about an HTML document. For example, information about the author of a Web page, the program or template used to generate the page, and keywords describing the content. META tags can appear anywhere in the HTML document, but are often placed near the top of the file, between the HEAD tags.
META tags are used to supply the following:
  1. Content/MIME type
  2. Copyright and author information
  3. Description
  4. Search engine keywords to locate particular pages

Using HTTP-EQUIV and NAME attributes

META tags work with two attributes: HTTP-EQUIV and NAME. The HTTP-EQUIV attribute adds information to the HTTP response header. The response header contains information that the server passes to the browser, such as MIME type information and other data that affect the browser. The NAME attribute is used to insert hidden information into an HTML document, such as the name of the page's author. This information is not used by the header. The HTTP-EQUIV and NAME attributes are interchangeable.
Learn more about META tags by examining the examples in the following MouseOver.

Content categories

The HTML <meta> element represents metadata that cannot be represented by other HTML meta-related elements, like <base>, <link>, <script>, <style> or <title>.
Every HTML element is a member of one or more content categories and these categories group elements that share common characteristics. This is a loose grouping (it does not actually create a relationship among elements of these categories), but they help define and describe the categories' shared behavior and their associated rules, especially when you come upon their intricate details. It is also possible for elements to not be a member of any of these categories.

meta Tag - Examples
In the next lesson, you will learn how to create a simple Web page.