Win 8 Metro IE and WordPress Favicon

With great difficult I’ve finally got my sites favicon showing up with IE 10 (Metro and Desktop) and thus showing when you pin a site to the metro home screen. For whatever reason Firefox and Chrome are far less fussy than IE about getting an icon to work, perhaps time for Microsoft to improve the code around the use of favicons to make it more user friendly.

So how did I do it.

  1. I used Greenfish Icon Editor Pro (Freeware) available from snapfiles here http://www.snapfiles.com/downloads/gficoneditor/dlgficoneditor.html none of the online converters were creating a file that would work with IE (note they would work with Firefox/Chrome).
  2. Uploaded the finished favicon.ico to the root directory of my website.
  3. Edited the header.php file for my theme, this file can be found in the following directory /wp-content/themes/themename/
  4. Added the following line of code to the aforementioned header.php file; <link rel=”shortcut icon” href=”http://www.alistairbeasley.com/favicon.ico” type=”image/x-icon” /> , this needs to go in between <head></head> but before <title /> prefrably as the first line after the opening <head> tag.
  5. After that if you’ve already viewed your page in IE you’ll need to completely delete your browsing history, a ctrl-f5 refresh won’t work.
  6. You should be done and when pinning the page to your Metro start screen you should see something like this.
Favicon on pinned IE10 Metro Start Screen
Metro Start Screen Favicon

Note that Metro will pull the dominant colour from your icon and use that as the tile colour, I assumed this would be white, however I suspect it must take an average of all the colours used.

Share
This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>