

Zaloguj lub Zarejestruj się aby uzyskać pełny dostęp do forum.
Posted 21 March 2011 - 21:35
Posted 21 March 2011 - 21:42
Posted 21 March 2011 - 21:56
Posted 21 March 2011 - 22:03
Posted 21 March 2011 - 23:40
Posted 21 March 2011 - 23:46
Posted 22 March 2011 - 00:37
Posted 22 March 2011 - 12:01
Posted 22 March 2011 - 12:27
Posted 22 March 2011 - 16:36
Posted 23 March 2011 - 16:43
Posted 23 March 2011 - 18:37
Posted 23 March 2011 - 22:28
Posted 23 March 2011 - 22:32
Posted 23 March 2011 - 22:38
Posted 23 March 2011 - 22:41
- (IBAction)grabURL:(id)sender { NSURL *url = [NSURL URLWithString:@"http://allseeing-i.com"]; ASIHTTPRequest *request = [ASIHTTPRequest requestWithURL:url]; [request startSynchronous]; NSError *error = [request error]; if (!error) { NSString *response = [request responseString]; } }Jeśli wyślesz zapytanie logowania to w stringu response będzie siedzieć jedynka wysłana przez Twój skrypt
Posted 23 March 2011 - 22:47
Posted 23 March 2011 - 23:10
Posted 23 March 2011 - 23:37
NSURL *url = [NSURL URLWithString:@"http://localhost/test/NSURLResponse_Test.php"]; NSMutableURLRequest *req = [NSURLRequest requestWithURL:url]; NSURLResponse *resp = nil; NSError *err = nil; NSData *responseData = [NSURLConnection sendSynchronousRequest: req returningResponse: &resp error: &err]; NSString *responseStr = [[NSString alloc] initWithData:responseData encoding:NSUTF8StringEncoding]; [B]lblMessage.text = responseStr[/B]; [responseStr release]; [err release];
0 members, 1 guests, 0 anonymous users