I\'m developing an RSS Reader and I need to get the favicon for each feed. For example, if my feed is google.com, I\'d like to get the \"G\" icon and put it into a UIImage or so
If you want the favicon, try calling this URL: http://www.google.com/s2/favicons?domain=
from within your app:
[NSURLConnection connectionWithRequest:
[NSURLRequest requestWithURL:
[NSURL URLWithString:@"http://www.google.com/s2/favicons?domain=google.com"]]
delegate:self];
Otherwise, an RSS channel's metadata has an optional element,
, which is described here: http://www.rssboard.org/rss-specification#ltimagegtSubelementOfLtchannelgt
For example:
en-us
Scientific American - News
Scientific American
http://www.scientificamerican.com
144
http://www.scientificamerican.com/media/logo/SAlogo_144px.gif
45
...
This image will typically be larger than a site's favicon, and likely not-square, but with some clever cropping and scaling, it can work as an icon if a feed's favicon isn't available.