Thursday 1 December 2011

Show a web site icon besides the website URL

Here I am discussing show an icon in the browsers address bar beside the site URL.
You just add this code to your head section of the html page.
code:

<html>
<head>
<link rel="shortcut icon" href="icon_name.ico">
</head>
<body>
<h1>Did you notice MSN icon is present in your address bar!!!!!</h1>
</body>
</html>

where 'icon_name.ico' is the name of the icon to be displayed.
This code works if the icon file exist in the same location of the html file.If this icon
is in a different location we must specify the location like
href="d:\icon_name.ico".



I am including a sample screen shot :


Hope that this post will be helpful to you.
With thanks Sukesh B R

No comments:

Post a Comment

Search This Blog