Try my app Expense Manager @ google play and amazon store.

Friday, April 20, 2012

HTML Advanced tutorial 20 : HTML head Elements

The head element is a container for all the head elements. Elements inside <head> can include scripts, instruct the browser where to find style sheets, provide meta information, and more. The following tags can be added to the head section

 <title>, <base>, <link>, <meta>, <script>, and <style>.

title Element
The <title> tag defines the title of the document. The title element is required in all HTML/XHTML documents. The title element
1). defines a title in the browser toolbar
2). provides a title for the page when it is added to favorites
3). displays a title for the page in search-engine results
For example,below is simplified HTML document.

<html>
<head>
<title>Title Here</title>
</head>
<body>
content Here.
</body>
</html>

base Element
The <base> tag specifies a default address or a default target for all links on a page. For example

<head>
<base href="http://www.yoursite.com/images/" />
<base target="_blank" />
</head>

link Element
The <link> tag defines the relationship between a document and an external resource. The <link> tag is most used to link to style sheets. For example

<head>
<link rel="stylesheet" type="text/css" href="mystylefile.css" />
</head>

style Element
The <style> tag is used to define style information for an HTML document.Inside the style element you specify how HTML elements should render in a browser:

<head>
<style type="text/css">
body {background-color:yellow}
p {color:blue}
</style>
</head>

The <meta> tag provides metadata about the HTML document.

The <script> tag is used to define a client-side script, such as a JavaScript.

HTML head Elements

Tag                Description
<head>           Defines information about the document
<title>             Defines the title of a document
<base />         Defines a default address or a default target for all links on a page
<link />           Defines the relationship between a document and an external resource
<meta />         Defines metadata about an HTML document
<script>          Defines a client-side script
<style>           Defines style information for a document

HTML Advanced tutorial 21 : HTML Meta  >>
<<  HTML Advanced tutorial 19 : HTML Styles

No comments:

Post a Comment

Follow by Email

Google+ Badge