Jason Cartwright's favicon app
Python
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
libs
templates
1px.gif
README.rdoc
cron.yaml
default.gif
globals.py
main.py
models.py
topsites.txt

README.rdoc

getFavicon

Retrieves the relevant favicon for a URL, or returns a default icon should it not be able to find it. Works better than the Google version as it will find favicons specified by an HTML page's <link> element.

Setup

Download Google AppEngine Python SDK and deploy the favicon code on a new appengine.

Original source

getfavicon.appspot.com/

Example

http://<appengine domain>/http://www.google.com?defaulticon=http://en.wikipedia.org/favicon.ico

Options

You can also pass the following defaulticon values for other responses when a favicon isn't found:

  • none: no default icon will be returned (and an HTTP 204 “No content” response code)

  • 1pxgif: 1px x 1px transparent GIF

  • lightpng: grey 'world' icon (as used by Google Chrome)

  • bluepng: light blue 'world' icon (as used by Google's favicon service)

De-cache

You can remove an icon from the cache by calling /decache/?domain=. E.g. /decache/?domain=www.google.com.

Original Copyright

License

No restrictions.