Favicon file is placed in a web server root directory. It is a page icon or associated with a particular website. For example when you visit our site you see favicon in the browser's URL bar, next to the site's name. Also it appears next to the site's name in lists of bookmarks, and next to the page's title in a tabbed document interface.
When you building new website, to distinct from others you need your logo and favicon. Directly with GIMP you can save .gif, .jpg or .png files which is not bad, but users with MS Internet explorer from Windows can only see blank sheet of paper where your branding should appear.
Under windows you can save file as .ico directly from GIMP. If you working from linux, you should have both GIMP and netpbm.
To get these installed, you should run
[code]
$ sudo apt-get install netpbm gimp
[/code]
in your terminal.
Step # 1: Convert logo to ppm raw format
- Open your logo using GIMP
- Now cut and paste logo in square
- Next resize logo by visiting Image > Scale image option. Set pixel size to 16 x 16 or 32 x 32 or 48 x 48.
- Next click on File > Save as > Enter file name as favicon.ppm > Click on Save > Raw Encoding > Ok
Step # 2: Convert portable pixmaps into a Windows .ico file
Now run the following command to create a .ico file:
[code]
$ ppmtowinicon -output favicon.ico favicon.ppm
[/code]
Step # 3: Upload favicon.ico file
Upload favicon.ico file to webserver root directory such as /var/www/html or /srv/httpd/kurapka.lt.
Step # 4: Favicon example
To activate favicon, modify your site pages or template by placing following code between <head>...</head> section:
[php]
<link rel="icon" href="<?php bloginfo('template_url'); ?>/favicon.ico" />
<link rel="shortcut icon" href="<?php bloginfo('template_url'); ?>/favicon.ico" />
[/php]
if your favicon.ico is in root folder.







