Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- NSString *stringUrl = [NSString stringWithFormat:@"http://xxxxxxxxx/login.php?Username=%@&Password=%@",YouruserName, Yourpassword];
- NSURL *url = [NSURL URLWithString:stringUrl];
- NSURLRequest *request = [NSURLRequest requestWithURL:url];
- [NSURLConnection sendAsynchronousRequest:request
- queue:[NSOperationQueue mainQueue]
- completionHandler:^(NSURLResponse *response,
- NSData *data, NSError *connectionError)
- {
- if (data.length > 0 && connectionError == nil)
- {
- NSDictionary *dicYourResponse = [NSJSONSerialization JSONObjectWithData:data options:0 error:NULL];
- }
- }];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement