Frage

I have this small problem men deploying my asp.net mvc project to a web server running on IIS 8. May seem like a minor, but my favicon is not displayed in the page tab. It works when running locally on Visual Studio development server.

Another thing I'm curious about is the fact that the icon is reciding in my root-folder, but I cannot seem to find any references to it in any of my cshtml-files. How come it works locally? (And, of course, not on server when published)

War es hilfreich?

Lösung

Solved by adding the following line:

<link rel="icon" type="image/x-icon" href="@Url.Content("~/favicon.ico")">

No idea why it works locally without this line though :/

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top