Skip to content

Instantly share code, notes, and snippets.

@hlxwell
Created May 15, 2013 09:43
Show Gist options
  • Save hlxwell/5582812 to your computer and use it in GitHub Desktop.
Save hlxwell/5582812 to your computer and use it in GitHub Desktop.
Get path for storing internet file to local
// Get a temp file path
[NSTemporaryDirectory() stringByAppendingPathComponent:@"myapptempdirectory.jpg"]);
// To get the filename from the url
[@"http://stackoverflow.com/questions/1098957/objective-c-extract-filename-from-path-string.jpg" lastPathComponent];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment