nsurlconnection

How to get iDevices's Serial Number from NSURLRequest/NSURLConnections (which be sent by an iDevices) by PHP

I have an iOS app send an NSURLRequest/NSURLConnections to PHP Webserver. How can i detect iDevices's Serial Number which sent NSURLRequest/NSURLConnections to my PHP Webserver? Anybody can help me? :) ...

Impossible issue connecting to Windows Live Messenger network

This issue is giving me serious headaches, I don't have a clue what's going on here. If you don't have any experience with the Windows Live network, I ask you to read this anyway, maybe it has nothing to do with it and am I overlooking something totally unrelated. In short: I wrote an Objective-C class that allows me to connect to the W...

Problem with NSURLConnection

Hi, I am getting this error "The certificate for this server is invalid. You might be connecting to a server that is pretending to be "server addres goes here" which could put your confidential information at risk." I am using this method: [NSURLConnection sendSynchronousRequest:request returningResponse:&response error:&error]; ...

XCode webview connection/server error handling

All, I am fairly new to XCode and am trying to get a handle on how to best deal with connection issues when trying to use a WebView. I know there are related questions on SO, but none seem to offer complete solutions. I have the following code, but it seems a little inefficient. Hopefully, someone can help me refactor it down to a po...

Cancelling an exsting NSURLConnection object

Hi All I am developing an application that has a tabBar. On tapping a tabBarItem a new connection object gets created with some URL. Now the problem is that as much items we select on tabBar, that much number of connection objects gets created and all runs simultaniously. I want to close the previous connection on selecting a new tabBar ...

Constructing a simple HTTP Post request to send a single image from iPhone

I'm trying to send a single image from my iPhone app to my Google App Engine Java server. On the server, I'm getting a FileUploadBase$InvalidContentTypeException, which is thrown when the request is not a multipart request. ServletFileUpload.isMultipartContent(req) is printing false. I'm trying to send an image, encoded as a jpeg, and...

how to make download of different files from one nsurlconnection

Hi, I am having a single file with 5 url to download 5 different files. What I am doing is calling the method which will change the url and make another call to download the file. how should it be ideally ? My requirement is sequential download of file. ...

NSURLConnection downloads only the first 567 bytes?

Hi, I'm trying to download http://www.vesseltracker.com/earth/vesseltrackerlight.kmz but am not getting all the bits and pieces. I tried: NSData *data = [NSData dataWithContentsOfURL: serverURL options: 0 error: &error]; to no avail then switched to - (void)startDownloadingURL:(NSURL*) url { // Create the request. NSUR...

How to abort async http connection in iphone ?

I initiated an async http call to the server in a viewcontroller, but it take long time sometimes. Can I put a button on it and then abort the running http call when user clicked that button ? and if that could be done, I'd like also implement this function when user exit current view like, navigate back to its parent view. ...

Refreshing data on iPhone causes the system to become unstable or unresponsive

Hi ,everyone I got problem here I need to update a plist data in a period time and I use Tab Bar to switch 2 views When I select to view1 ,It will load data from an URL But if I switch to view2 , the view1 still update the data If you switch to view2 and switch back ,view2 keep updating the data. and this is the code I'm using to ...

using nsurlconnection calculate remaining time for download

hi, I am downloading a 25+ mb file from the server. Is there a way to predict the remaining time to download ? if yes how ? ...

Is it safe to use the "hash" method to track NSURLConnections in memory?

My question is related to this discussion: http://www.cocoabuilder.com/archive/cocoa/202211-how-to-get-nsurl-form-nsurlconnection.html I am sending several NSURLConnections to transmit data and need to be able to tell which specific connection failed or succeeded. There are NSURLDelegate methods (didFailWithError, etc) which return the ...

What the difference in using async NSURLConnection from a static method with an object as delegate, and calling it IN an object with self as delegate?

When i try to send – initWithRequest:delegate:startImmediately: message to NSURLConnection from a class method, passing an ad-hoc delegate object, delegate methods never gets called. When, instead, – initWithRequest:delegate:startImmediately: is sent by an object, and the delegate of NSURLConnection is self, than all goes OK. Someone can...

iphone wireless connection, connectivity fails after turning wireless off/on again

i have a pretty basic iphone app, makes some web calls with: NSData *response = [NSURLConnection sendSynchronousRequest:request returningResponse:nil error:nil]; In testing, if I stop the app, turn off wireless, and restart the app (not kill and restart, just bring to foreground), I continue to get errors on any network url attempts. ...

NSURLConnection Problem with NSOperationqueu

Hi I am trying to create a NSOperaion Queue to download a bunch of PDF files. But it doesnt work. The delegate methods dont get called for NSURLConnection since i put them in NSOperation queue.... any alternatives or solution??? - (void) loadData { NSOperationQueue *queue = [NSOperationQueue new]; NSInvocationOperation *operation; fo...

I am getting error in sending argument with space.

Hi all. I am sending argument from my iphone application to php page to genrate xml given below. feedurl=@"http://www.abc.net/feed/index_clatest.php?more=s-laday gaga"; The url run in mozila when it runs. but when i run it in my iphone application i get the following error. erminating app due to uncaught exception 'NSInvalidArgumen...

cancel a SynchronousRequest in iPhone SDK. (TIMEOUT Interval not wokring)

Hello, I've queried this forum for hours looking for an idea/answer/solution for my problem, but came up empty every time. i have created a SynchronousRequest using the following: NSMutableURLRequest *theRequest = [[NSMutableURLRequest alloc] initWithURL:url]; NSString *msgLength = [NSString stringWithFormat:@"%d", [params len...

NSURLConnection and ProgressBar Crash when try to convert to float

Hi Guys i am trying to use progressbar while downloading using NSUrlConnection am missing somthing but dont know what see my code in my .h i have NSMutableData *receivedData; NSNumber *FileSize; which i use to calculate a precent for progressbar in my .m - (void)connection:(NSURLConnection *)connection didReceiveRespon...

ASIHTTPRequest Problem

Is anyone else having this problem with ASIHTTPRequest? It seems that when I perform an async request from within a background thread with delegate set to the instance I can run into trouble as the delegate can be freed before the request (which is put into an NSOperationQueue) returns a callback. It seems that ASIHTTPRequest doesn't r...

Returning data from data-grabbing class from web?

I'm trying to create a class which will let me get requested data from a web service. I'm stuck on how to return the values. // FooClass.m // DataGrabber is the class which is supposed to get values dataGrabber = [[DataGrabber alloc] init]; xmlString = [dataGrabber getData:[NSDictionary dictionaryWithObjectsAndKeys:@"news", @"instructio...