Unfortunately today has been slightly frustrating. We wanted to learn how to fetch documents from the web in Objective-C so we went to Apple’s iPhone How-To Library and looked at the Getting Started document on fetching the contents of a URL.

The process of fetching the contents of a URL turns out to be incredibly complex involving delegates, many objects and such. The logic of it all was terribly cumbersome but also fairly general so we decided we should wrap it up to create a utility class for our apps to use. Which of course involved another level of delegate objects, blah, blah, blah.

Then we saw [NSString stringWithContentsOfURL]

/FACEPALM

Dear Apple,

When we go to your How-To Library and we read your Getting Started document on Networking and fetching files from the web…. FRAKKING START WITH THAT.

Thanks,
Bordering On Insanity

Fetching a Web Page Easy Mode

Leave a Reply

Your email address will not be published. Required fields are marked *