Page 1 of 1 [ 4 posts ] 

Silver_Meteor
Veteran
Veteran

Joined: 10 Jul 2007
Gender: Male
Posts: 1,399
Location: Warwick, Rhode Island

05 Nov 2007, 8:37 pm

Some websites have those little avatars(pictures) to the left of their website address when you type in the website address. How do you set something like that up if you have a personal website?


_________________
Not through revolution but by evolution are all things accomplished in permanency.


Brooks
Snowy Owl
Snowy Owl

User avatar

Joined: 1 Nov 2007
Age: 58
Gender: Male
Posts: 153
Location: Alabama

05 Nov 2007, 8:57 pm

I believe that you are talking about the favicons in the address bar.

The easiest way to do this is to create or find an icon in the .ico format and name it as favicon.ico and place it in the root directory of your website. All modern web browsers should pick it up and display it.

For best compatibility and quickest download times, the favicon should be either 16x16 or 32x32.

There are more advanced ways to do this that use other file formats and html encoding, but this way is the quickest and easiest to do.


_________________
And the world is queer
And the human is strangest of all


lau
Veteran
Veteran

User avatar

Joined: 17 Jun 2006
Age: 76
Gender: Male
Posts: 9,795
Location: Somerset UK

06 Nov 2007, 7:21 pm

Merely putting the icon in the root directory is not sufficient, although there doesn't seem to be a great deal of consensus on this.

I use the lines:

Code:
<link rel="icon" href="images/favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="images/favicon.ico" type="image/x-icon" />

in the "head" of the (x)html documents, where images/favicon.ico is whatever image you want displayed.
It doesn't HAVE to be in the "x-icon" type.
You must expect them to be displayed as 16x16. If they aren't that size to start with, browsers will scale them, if you're lucky, with results you might not be impressed by.

The only problem with the above is that it assumes your website (x)html head section is under your control. Unfortunately, that's not always the case.

See http://en.wikipedia.org/wiki/Favicon.


_________________
"Striking up conversations with strangers is an autistic person's version of extreme sports." Kamran Nazeer


Silver_Meteor
Veteran
Veteran

Joined: 10 Jul 2007
Gender: Male
Posts: 1,399
Location: Warwick, Rhode Island

12 Nov 2007, 12:00 am

I was able to put a favicon on my website with a favicon generator. Though it was kind of random. Anyway, its on there.


_________________
Not through revolution but by evolution are all things accomplished in permanency.