0
ASIFormDataRequest *request = [ASIFormDataRequest requestWithURL:[NSURL URLWithString:@"http://trade2rise.com/project/dry/windex.php?itfpage=register"]];
    ASINetworkQueue *networkQueue = [[ASINetworkQueue alloc] init];
    [request setPostValue:txt_name.text forKey:@"name"];
    [request setPostValue:txt_con_number.text forKey:@"phone"];
    [request setPostValue:txt_email.text forKey:@"email"];
    [request setPostValue:txt_pwd.text forKey:@"password"];
    [request setPostValue:txt_con_pwd.text forKey:@"password2"];
    [request setDelegate:self];
    [request setDidFinishSelector:@selector(requestFinished:)];
    [request setDidFailSelector:@selector(requestFailed:)];
    [networkQueue addOperation:request];
    [networkQueue go];

我是 Iphone 新手 请解释一下上面的术语?

4

1 回答 1

1

如果你知道 http post 方法,你就会知道 post 表单中的键值对。所以上面的代码就像向表单添加相对键和值,添加队列以发布请求。

ASIFormDataRequest *request // url绑定请求,表单post表单

ASINetworkQueue *networkQueue // 工作队列中维护请求的队列(FIFO)

于 2014-10-14T05:28:04.803 回答