I have a file URL and want to download it in my iPhone in document directory. So that I can use this downloaded file within other application like, share it on whatsApp, in email attachment etc.
I am using ASIHTTPRequest, what Destination path I should set?
ASIHTTPRequest *request = [ASIHTTPRequest requestWithURL:self.ImageURL];
[request setDownloadDestinationPath:@"What Path I should Set"];
[request startSynchronous];
Here is a sample url of file which I want to download: http://www.fourspan.com/apps/agentreview/public/img/ads/1441791507_Muhammad.jpg
Firstly,
ASIHTTPRequestis obsolete, please avoid using it.Here is the code using
AFNetworkingto download any file and save it to any location you want (savePath)