Re: favicon of address
Re: favicon of address
- Subject: Re: favicon of address
- From: Jens Alfke <email@hidden>
- Date: Mon, 21 Sep 2009 09:34:17 -0700
The best engineered approach would probably be to load the page up
into a WebView, BUT use the WebResourceLoadDelegate to stop it
wasting time downloading any resource that isn't the favicon.
WebView has a lot of overhead! It would be much more efficient to just
use NSXMLDocument to download and parse the HTML. Using the XPath
accessor methods in NSXML you can very easily search for that
particular link and extract its URL.
It shouldn't take more than three or four lines of code if you don't
mind doing it synchronously; if you want async, then use an
NSURLRequest to download the HTML and pass the resulting data to
NSXMLDocument.
—Jens_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden