2010
06.26

A favicon (short for favorites icon), also known as a website icon, shortcut icon, URL icon, or bookmark icon  is a 16×16, 32×32 or 64×64 pixel square icon associated with a particular website  or webpage. Browsers that provide favicon support typically display a page’s favicon in the browser’s address bar and next to the page’s name in a list of bookmarks. Browsers that support a tabbed document interface typically show a page’s favicon next to the page’s title on the tab.

Associating the Shortcut Icon with Your Web Page

After creating the icon, you must associate it with your Web page. There are two methods for doing this.

  1. The first method is to save the icon with the default file name of favicon.ico to the root directory of your domain—for example, www.tejaspmehta.com/favicon.ico.
  2. The second method for associating a shortcut icon with your Web page is to add a line of HTML code to the page’s head  element. The line of code includes a link  tag that specifies the location and name of the icon file.


<head>
<link rel="SHORTCUT ICON" href="http://www.tejaspmehta.com/myicon.ico"/>
<title>My Title</title>
</head>

You can use either method, or both. However, if you use the second method, whichever icon you point to in the link tag on each page will be displayed instead of the default favicon.ico file at the root of your domain.

No Comment.

Add Your Comment
Rss Feed Tweeter button Facebook button Linkedin button