Page 1 of 1

URL image?

Posted: Thu Jun 10, 2004 5:03 pm
by Joe
Is there any technique in PHP which allows you to enter a small image in the url bar when people visit your site. Just like when you goto PHP-dn and you look at the url bar and see the image on the left hand side. Is it possible to do this with PHP?

Thanks!

Posted: Thu Jun 10, 2004 5:07 pm
by dull1554
its not a function of anything, if im not mistaken its just a file placed in the root of your web space that is named favicon.ico

Posted: Thu Jun 10, 2004 5:09 pm
by scorphus
dull1554 is right. Create/get a 16x16 icon, name it favicon.ico, put it in your server root directory and add the following html code to the <head></head> section of every page of your site:

Code: Select all

<link rel="SHORTCUT ICON" href="favicon.ico">
Scorphus.

Posted: Thu Jun 10, 2004 5:34 pm
by dull1554
thanks for the tag team, i did not know that html was required i thought the web server did all the work

Posted: Thu Jun 10, 2004 5:34 pm
by Joe
Ahh ok thanks alot. It was something which I was confused about but now I know. I cannot thank you guys enough!

Cheers!

Posted: Thu Jun 10, 2004 6:24 pm
by Joe
OK this is stupid but the image does not seem to appear in the url when I put the .ico file into the root directory and included the html between the head tags. Any further suggestions?

Posted: Thu Jun 10, 2004 6:31 pm
by scorphus
No problem, Joe.

dull1554, it is not really required, the web server does the work, but to conform with standards or to change the icon in other page you can use the <link> tag.

Scorphus.

Posted: Thu Jun 10, 2004 6:36 pm
by Joe
YAY its alive, lol. Thanks alot scorphus and dull1554. Much appreciated!

Posted: Thu Jun 10, 2004 6:41 pm
by dull1554
no prob, really did not do much.....====>>>>thank scorphus for further info, i just kinda nudged you in the right direction.........:)