IoooooooooooooS
  • 3
  • 新人请关照

大神快来啊 得图云ios sdk 更新了 AFNetworking 2.3.1框架后总是上传失败

    NSString *policy = [self getPolicyWithSaveKey:saveKey];
    NSString *signature = [self getSignatureWithPolicy:policy];
    //NSString * httpMethod = @"POST";
    NSDictionary * parameDic = [NSDictionary dictionaryWithObjectsAndKeys:policy,@"postdata",
                                signature,@"signature", nil];
    [[AFHTTPRequestOperationManager manager] POST:API_DOMAIN parameters:parameDic constructingBodyWithBlock:^(id<AFMultipartFormData> formData) {

        [formData appendPartWithFileData:data name:@"file" fileName:@"file.png" mimeType:@"multipart/form-data"];
    } success:^(AFHTTPRequestOperation *operation, id responseObject) {

    } failure:^(AFHTTPRequestOperation *operation, NSError *error) {

    }];

返回结果
Not accept Signature is error
不知道是不是需要特殊设置
大神快来啊

阅读 2.5k
评论 2014-09-24 提问
    2 个回答

    检查一下access_secret对不对。

    后台
    图片描述

    评论 赞赏 2014-09-29

      name:@"file"要跟服务器一致

      评论 赞赏 2014-10-09
        撰写回答

        登录后参与交流、获取后续更新提醒