What ways can I put FAVICON on my website?

I looked on the network as different sites put their icon on the site. Whenever I try to do this myself, I end up hacking until he just decides to work.

I assume that I have 2 questions in one.

  • How does this site add it? - http://www.fbd.ie

    I can not find favicon.ico in this page source.

  • Besides including <link rel="shortcut icon" href="/favicon.ico"> , how can I enable the icon?

+4
source share
3 answers
  • There is probably a file in the root directory of the website called favicon.ico . Most browsers will look there by default regardless of whether there is a <link> or not.
  • See the answer to # 1.
+1
source

The easiest way to add favicon is to simply put a file called favicon.ico in the root directory of your website.

Browsers will find this automatically.

You can also specify the <link> . Any of them will work:

 <link rel="icon" type="image/vnd.microsoft.icon" href="http://example.com/image.ico"> <link rel="icon" type="image/png" href="http://example.com/image.png"> <link rel="icon" type="image/gif" href="http://example.com/image.gif"> 

Edit: I see you already knew that .: D

+12
source

All you have to do is include the file in the root of your site. Browsers are designed to automatically request this — you'll see a large number of requests for its 404th in your weblogs, if you don't have them.

From Wikipedia:

The original favicon determination tool, introduced on Internet Explorer 4, placed a file called favicon.ico in the root of the web server directory. It is then automatically used on the Internet Favorites Favorites (bookmarks) display. Later, however, a more flexible system was created using HTML to indicate the location of the icon for any given page. As shown below, this is achieved by adding an element link to the document section, which indicates the type of image file and its location. In this way, any image file specified can be used as a standard.

The essential point is that you do not need to do anything in your HTML markup or any other resource file. Just upload the file to the root directory.

0
source

All Articles