七牛云存储 - iOS的七牛SDK如何支持后台上传文件
PHP中文网
PHP中文网 2017-04-17 16:14:34
0
1
640
PHP中文网
PHP中文网

认证0级讲师

reply all(1)
巴扎黑

The iOS SDK has an upload function that can be called directly,

    NSString token = @"从服务端SDK获取";
    QNUploadManager *upManager = [[QNUploadManager alloc] init];
    NSData *data = [@"Hello, World!" dataUsingEncoding : NSUTF8StringEncoding];
    [upManager putData:data key:@"hello" token:token
        complete: ^(QNResponseInfo *info, NSString *key, NSDictionary *resp) {
        NSLog(@"%@", info);
        NSLog(@"%@", resp);
    } option:nil];

If you are talking about letting your backend upload to your server, then you can also let your backend server access the server's SDK:

http://developer.qiniu.com/docs/v6/index.html

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template