Linked Questions

1 vote
0 answers
2k views

How can I convert NSDictionary To URL QueryString in iOs ? for example : NSDictionary *params = @{@"a":@1, @"b":@2} NSString queryString = convert(params); // a=1&b=2
ken's user avatar
  • 131
0 votes
0 answers
155 views

Are there any built in methods (or really simple examples, not using libraries) that can turn a dictionary into a url parameter string (to be appended to url). I'm expecting something similar to the ...
anson's user avatar
  • 4,174
1 vote
0 answers
29 views

This is my Api and i need to pass values for Passport number Expiry data and other fields i know to pass data when its just normal values. I am not sure how to pass data inside the Dictionary Passport ...
iOSDeveloper's user avatar
9 votes
1 answer
7k views

I'm seriously having a brain fart here, but I can't figure out why this isn't encoding for the life of me. Been searching all over, and I can't even get the code samples to encode. Any ideas? ...
JoeCortopassi's user avatar
16 votes
3 answers
21k views

AFNetworking allows you to add an NSDictionary of parameters to a request, and it will append them to the request. So if I wanted to do a GET request with ?q=8&home=8888 I'd just making an ...
user avatar
8 votes
3 answers
12k views

I have to send array of dictionaries via POST request. For example: materials: [[String, String]] = [ [ "material_id": 1, "qty": 10 ], [ "material_id": 2, "qty": 5 ] ] ...
Nemmo's user avatar
  • 209
5 votes
3 answers
6k views

I've looked everywhere, and haven't found a single definitive answer in iOS. I'm trying to escape ampersands in my URL queries, but stringByAddingPercentEncodingWithAllowedCharacters(NSCharacterSet....
slider's user avatar
  • 2,816
1 vote
2 answers
6k views

Searching the web for some method to send POST requests in Objective-C, I came up with some solutions. That's what I've got: responseData = [NSMutableData new]; NSURL *url = [NSURL URLWithString:@"...
aur0n's user avatar
  • 473
4 votes
1 answer
3k views

How can I add GET parameters to an ASIHttpRequest? I want to go from http://mysite.com/server to http://mysite.com/server?a=1&b=2 programmatically. I have all my parameters as key-value pairs in ...
nurnachman's user avatar
  • 4,575
1 vote
3 answers
4k views

I created a method to build URLs for me. - (NSString *)urlFor:(NSString *)path arguments:(NSDictionary *)args { NSString *format = @"http://api.example.com/%@?version=2.0.1"; NSMutableString *...
6 votes
2 answers
2k views

I'd like to make a POST call that has both URL parameters and a JSON body: URL http://example.com/register?apikey=mykey JSON { "field" : "value"} How can I use two different serializers at the same ...
petard's user avatar
  • 333
2 votes
2 answers
1k views

So I'm trying to do an async POST request to my server from my iOS device. Here's the Swift code I've written: var urlString = "https://eamorr.com/ajax/login.php" var url = NSURL(string: ...
Eamorr's user avatar
  • 10.1k
0 votes
2 answers
2k views

I got an dictionary which looks like: ["foo": "whatever", "this": "that", "category": ["cat1", "cat2"]] and I need it to be a string like: foo=whatever&this=that&category=cat1&category=...
Leo's user avatar
  • 410
0 votes
1 answer
1k views

I am quite new to Objective-C and this is the first time I have attempted to implement MVC. I have a model class where l have an NSArray which will be populated with data from a JSON object. I want to ...
Greg J Arden's user avatar
1 vote
1 answer
519 views

Code: arrValues = [[NSMutableArray alloc]initWithObjects:@"Chennai", nil]; arrKeys = [[NSMutableArray alloc]initWithObjects:@"loc", nil]; dicValue = [NSDictionary ...
user3823935's user avatar

15 30 50 per page