Hi all,
I'm using NSURLConnection for downloading some images in my app currently.
Before implementing via this, I implemented it by NSData(dataWithContentOfURL) in NSThread.
But I wanted to cancel during downloading images, So I changed it to NSURLConnection.
But It happens other problem.
Performance was very low after changing.
For ...
If the website doesn't require authentication, my code works fine, if it does, it errors with EXC_BAD_ACCESS right after printing "credential created". I'm not releasing anything, and this code is copied straight from the documentation - any idea what's wrong?
- (void)connection:(NSURLConnection *)connection didReceiveAuthenticationCha...
a scenario is below.
I made two Controllers, A tableViewController, B viewController and C ScrollView.
A tableViewController has cell that is entering to B viewController.
and B viewController has C scrollView that is B's front View.
C scrollView has object of NSURLConnection.
and this functioned to download an image.
( A -> pushViewC...
Hey,
I ran into a problem. I can't image why that happens, probably you guys can.
I've created a UIBarButtonItem in IB and linked it correctly. A set the property and synthesized it. At the beginning I set the btn disabled (viewWillAppear).
Then I try to add an entry to my mysql db:
NSString *URLStr = [NSString stringWithFormat:@"http...
I am trying to call an https web service (RESTful) using basic authentication.
It works fine if I put the credentials in the url itself but I would rather add it to the request so that the password does not appear, for instance in an exception.
I am using the following code:
NSURLCredential *credential = [NSURLCredential credential...
hi all,
I encounter a problem by following your comment. I would like to download different file at same time with different delegate:
.h:
NSMutableData *fileData;
.m:
NSString *imgfile = [NSString stringWithFormat:@"http://xxxx/01.jpg"];
NSURL *fileURL1 = [NSURL URLWithString:imgfile];
NSString *audiofile = [NSString stringWithFo...
Any idea why sendSynchronousRequest is causing a leak below? Instruments states that the responsible frame is NSURLConnection and it points at a NSCFString leaked in the line with sendSynchronousRequest.
I've read that this was a known issue before OS 2.2 or something, but should definitely be fixed now. Any thoughts?
[UIApplication ...
I have a UITableView whose cells contain custom ImageViews that asynchronously load the images from the internet. To load those images I use NSURLRequest and NSURLConnection which works fine. The only problem is that the images are not cached and therefore are downloaded every time they are used. I tried to set the cachePolicy of the NSU...
Hello Gentlebeings,
I have a weird issue. Here is the setup:
I have a NSOperationQueue which I add NSOperation subclass objects to. These do networking using NSURLConnection sendSynchronousRequest method. As I understand it, these are completely asynchronous, since they are NSOperations which each get their own thread.
If I launch my ...
I use the following code:
- (NSURLRequest *)connection:(NSURLConnection *)connection willSendRequest:(NSURLRequest *)request redirectResponse:(NSHTTPURLResponse *)response {
NSLog(@"Received redirect Response: %@ %@", [response allHeaderFields], [NSHTTPURLResponse localizedStringForStatusCode:[response statusCode]]);
return request;
}
...
Im researching the best plan of attack for creating a form that gathers information from the user and sends this dates to a server.
I thought I would run my thinking past you all and get some feed back.
To create the actual form I plan on using a table view and navigation controller much like the from used to create a new contact in the...
I'm trying to download several images in response to a single http request. On the server side (java) I'm using oreilly multipart response and I'm getting my datas in my iPhone Simulator in didReceiveData (approximately one call for each image) after a call to didReceiveResponse (approximately one call for each image as well) in my deleg...
I am writing an app that caches streaming content from the web on the iPhone. Right now, I'm saving data to disk as it arrives (in chunk sizes ranging from 1KB to about 60KB), but application response is somewhat sluggish (better than I was expecting, but still pretty bad).
My question is: does anyone have a rule of thumb for how freque...
I have a sql image type field coming back in an EDM (Entity Data Model) .NET service call. The image field is stored as binary in sql server 2008. However, I'm not sure what is happening to the image data, or what type of encoding. And since the webservices are generated behind the scenes, I can’t figure out if the service is doing somet...
So here's my issue:
I followed the NSURLConnection tutorial in the iPhone Developer Documentation almost to the T, and it only kinda works.
Here's where it all goes wrong:
The object seems to be created correctly and delegates to connectionDidFinishLoading, but with any URL I try to load the response data always ends up only being 0 by...
I am downloading some very large data from a server with the NSURLConnection class.
How can I implement a pause facility so that I can resume downloading?
...
Hey guys,
I just noticed that when you get a network interruption the code proposed by Apple fails to load the images ... It works perfectly otherwise though ;)
It is due to the fact that IconDownloader doesn't do anything if NSURL connection fails ...
Before I struggle with this on my own, anyone has any tips for me :D ?
Thanks a l...
My Rootviewcontroller uses NSURLConnection to get data from a server, and then, based on this data, loads a bunch (like 7) of smaller UIViewControllers that each also use their own NSURLConnection to get some more specific data from the server. But, the problem is, only the RooTViewController is recieving callbacks from:
- (void)connect...
I am having a problem with a network request that should timeout, but the method is not called. The request is as follows:
#define kCONNECT_TIMEOUT 20.0
request = [NSMutableURLRequest requestWithURL: aUrl];
[request setHTTPMethod: @"POST"];
postData = [jsonData dataUsingEncoding:NSASCIIStringEncoding];
[request setHTTPBody:postData];
...
Hi all~.
I made a multi files downloader.
I implemented NSURLConnection using NSOperationQueue.
NSOpetationQueue has many NSURLConnection operations.
and, set MaxConcurrentOperationCount to 10.
I thought my code is right, But after run the project, it was wrong.
there are some connection error has occured.
files url were right. and f...