Search code examples
asp.net-mvcinternet-explorer-8favicon

why wont the fav icon show up in IE on my asp.net-mvc site


i have this line in my asp.net-mvc page.

<link rel="icon" type="image/x-icon" href="/content/images/icons/favicon.ico" />

the favicon shows up fine in Firefox but it doesn't show up in IE8 at all.

any suggestions on why this doesn't work in IE8 ?

also, under RegisterRoutes, i have this:

   routes.IgnoreRoute("favicon.ico");

i have tried everything on this page and it still doesn't seem to work for IE8


Solution

  • The Wikipedia article about favicon has a pretty good overview on how you specify the favicon and which file formats are supported.

    The agreed standards is a bit in conflict with the de-facto standards. For example, the non-standard rel value shortcut icon has wider support than the standard value icon. You might want both a standard and a non-standard link tag to cover more ground.

    Most browsers will pick up the favicon if you simply put it in the root folder, so that would be the best place to put it even if you also have a link tag that points to it.

    Even if you do everything right, there is still no guarantee that the favicon will show up in any specific browser. Sometimes it simply doesn't work, for some unknown reason.