Google propose un service permettant d'afficher automatiquement le favicon (définition sur  Wikipédia) d'un site, converti au format png.

Il suffit d'afficher l'image suivante :

<img src="http://www.google.com/s2/favicons?domain=domaine.extension" />

en remplaçant domaine.extension par ceux correspondant au site (sans http://).

Par exemple :

<ul>
    <li><img src="http://www.google.com/s2/favicons?domain=google.fr" alt="" />&nbsp;<a href="http://www.google.fr">http://www.google.fr</a></li>
    <li><img src="http://www.google.com/s2/favicons?domain=cowblog.fr" alt="" />&nbsp;<a href="http://www.cowblog.fr">http://www.cowblog.fr</a></li>
    <li><img src="http://www.google.com/s2/favicons?domain=facebook.com" alt="" />&nbsp;<a href="http://www.facebook.com">http://www.facebook.com</a></li>
</ul>

2 septembre 2009 TutoCow

Aucun commentaire n'a encore été ajouté !
 

Ajouter un commentaire









Commentaire :








Votre adresse IP sera enregistrée pour des raisons de sécurité.
 

La discussion continue ailleurs...

Pour faire un rétrolien sur cet article :
http://www.latelament.fr/trackback/2899083

 

<< Page précédente | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | Page suivante >>

Créer un podcast