Ad

html head Tag

 

 Head section



Head section

   The head section container set of elements that provide the metadata for the document. This the metadata can be specify the title element, character set, author, description or keywords of  web page (meta element), a style sheet or relational information (link element) or embedded style declarations (style element), among others. The presence of  title element is mandatory to the inside the head section of  HTML document. Most metadata  not displayed in the browser (although  title usually appears in the browser's title bar) it can be useful for the functionality of the page.

Syntax:

 The <head> tag is written as <head></head> with the metadata content enclosed between the start and end tags. The <head> tag  placed between  opening and closing <html> tags. Most HTML pages must have a <title> tag within the <head> tag.


<!doctype html>

<html>

<head>

<title> Page ...</title>

</head>

<body>

Page body...

</body>

</html>

the HEAD element, only to the certain elements are allowed. Information to the HEAD element may include to the following elements (arranged alphabetically)

1. Base Element  

The <base> element specifies the base URL and/or target for all relative URLs in a page. It is used either a href or a target attribute present, or both.

 Syntax

<base> is written as <base href="" target="">. It is used either a href attribute or


Example

Specified a default URL and a default target for links on  page: 

<html>

<head>

<base href="http://google.com/docs/mypage.html" target="_blank">

</head>

<body>

<h1>The base element</h1>

<P>the head section</p>

<p> specified a relative address.specified a base URL in head section</p>

<img src="images/about.gif">

</body>

</html>


2. ISINDEX

The ISINDEX element informs to HTML user agent the document is an index document. The document  queried with  keyword search by adding a question mark to the end of the document address, followed by a list of keywords separated by plus signs.The URL use for processing querie can be overrid with the HREF attribute. 

 <ISINDEX HREF="Personal.db" PROMPT="Enter Surname : ">


3. LINK

The LINK element indicates a relationship between the current document and an external LINK The LINK element indicates a relationship between the current document and an external resource. The <link> tag is the most  used to the link a external style sheets:

 LINK element  empty (does not have  closing tag), takes to the  same attributes as the anchor element.

<head>

<title> Linking stylesheet</title>

<link rel="ess stylesheet" href="style.css">

 </head>

The syntax is <link rel=" " href=" ">. rel attribute specifies to the relationship between  document containing the hyperlink and the destination resources. href attributes specifies to address of the hyperlink.

Related Post :-

html input type

CSS in combinators

css box property

No comments

Powered by Blogger.