homepage Welcome to WebmasterWorld Guest from
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / HTML
Forum Library, Charter, Moderators: incrediBILL

HTML Forum

Favicon question

 2:31 am on Jun 28, 2011 (gmt 0)

Hello, i have noticed for a long time that some sites use to specify the favicon in two places, like this:

<link rel="icon" href="favicon.ico" />
<link rel="shortcut icon" href="favicon.ico" />

Dos anyone know why?
Is there some browser issue, that needs both ?
I have only set the shortcut icon line, on my site.



 7:12 am on Jun 28, 2011 (gmt 0)

I did some research on this back in 2007, not sure if it still applies.

Stop all those favicon 404s!

At that time, using the rel="shortcut icon" in addition to rel="icon" was to address compatibility issues with IE which used the rel="shortcut icon". I've done some quick scanning and it appears that this was an issue up to IE6. IE7+ appear to support the rel="icon" which is the official link type. Link type "icon"

I still use both but I haven't researched the latest on compatibility issues such as those back in 2007. Anyone else got any updated information on use of both rel="shortcut icon" vs rel="icon"?


 7:41 am on Jun 28, 2011 (gmt 0)

Just for fun, about six months ago, on a site where it was fun and no biz (info thingie) never inserted any link to favicon... just put one in the root. Guess what? Loaded anyway. Kind of makes you wonder... (and I'm not talking about dev browsers... users, friends and family can see it, too).

That said, best to do it right and insert the link...

PS: Put the favicon in there to prevent 404s since the bots/browsers were looking for it... didn't care if it showed or not...


 8:50 am on Jun 28, 2011 (gmt 0)

Guess what? Loaded anyway. Kind of makes you wonder...

I think browsers will, by default, look for "favicon.ico" in the web root. But modern browsers do support other kind of image formats these days... gifs, pngs, etc. And for these you will have to specify the LINK.


 10:03 am on Jun 28, 2011 (gmt 0)

I haven't checked on this for a long time but IIRC IE6 and earlier needed an explicit reference. No idea about later releases. Every version of Firefox that I have used found the favicon without any help.

Global Options:
 top home search open messages active posts  

Home / Forums Index / Code, Content, and Presentation / HTML
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved