XHTML » Tags » title

Syntax:
<title> ... </title>

The title tag is used to provide a name or a title for your HTML document. There can only be one title element per document. The title is usually displayed as a text header by the browser in a special title or status window. If you do not provide a title, many browsers will display a default title. However, it is to your advantage to provide a meaningful and descriptive title for your site. For example, titles are sometimes used as the default text for links.

A well-formed XHTML document must contain properly nested and closed html, head, title, and body tags. The title must appear inside the head element. It cannot contain any other HTML tags. It can only contain text or be empty. However, you can use character entities (such as &nbsp; for spacing).
 
The separate closing tag is mandatory.
 

Examples

Code:
<html>
<head>
<base href="http://www.devguru.com/">
<link rel="stylesheet" type="text/css" href="include/StylesDefinitions.css">
<title> DevGuru </title>
</head>
<body>
...
</body>
</html>
Language(s): XHTML

See Also: