ASIHTTPRequest 上传框架支持文件;使用文件上传ASIFormDataRequest; NSString *s = @"文件传输"; NSURL *url = [NSURL URLWithString:@"http://localhost:8080/text"];//传输地...
分类:
移动开发 时间:
2015-07-07 12:44:13
阅读次数:
138
实例 01:#import "ViewController.h"@interface ViewController ()@property(nonatomic,strong) UIImageView *imageViews;@property (nonatomic, strong) NSURL *u...
分类:
其他好文 时间:
2015-07-06 17:30:25
阅读次数:
109
NSURL *url = [NSURL URLWithString:@"https://www.baidu.com"]; NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url]; req...
分类:
其他好文 时间:
2015-07-05 18:23:40
阅读次数:
100
AVAudioPlayer是AVFoundation框架中播放音频的一个类,此次使用的比较简单,今后涉及音频方面的用法,再增加总结每个AVAudioPlayer对应一个音频,主要创建方法为- (instancetype)initWithContentsOfURL:(NSURL *)url error...
分类:
移动开发 时间:
2015-07-05 00:54:44
阅读次数:
266
//初始化当前视图 _currentImageView = [[UIImageView alloc] init]; [_currentImageView setImageWithURL:[NSURL URLWithString:[array_pic objectAtI...
分类:
移动开发 时间:
2015-07-03 12:13:47
阅读次数:
119
前一篇文章用c#处理了证书,这次就使用oc来试一下,其实基本原理累似,一般都是自己覆盖几个函数,然后自己处理证书相关的东西。
自己创建一个类,如:
@interface MyURLConnection : NSObject
- (void) sendPostRequest: (NSURL*)url postData: (NSData*)postData;
@end
我比较喜欢把一些不需...
分类:
Web程序 时间:
2015-07-02 15:48:36
阅读次数:
146
// //判断是否安装QQ// if ([[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"mqq://"]]) {// // NSLog(@"install--");...
分类:
其他好文 时间:
2015-07-02 11:52:15
阅读次数:
123
由于url支持26个英文字母、数字和少数几个特殊字符,因此,对于url中包含非标准url的字符时,就需要对其进行编码。iOS中提供了函数stringByAddingPercentEscapesUsingEncoding对中文和一些特殊字符进行编码,但是stringByAddingPercentEsc...
分类:
Web程序 时间:
2015-07-01 22:11:19
阅读次数:
171
#pragma mark - helper- (NSURL *)convert2Mp4:(NSURL *)movUrl { NSURL *mp4Url = nil; AVURLAsset *avAsset = [AVURLAsset URLAssetWithURL:movUrl options:.....
分类:
其他好文 时间:
2015-07-01 17:29:32
阅读次数:
113
[NSDate date]可以获取系统时间,但是会造成一个问题,用户可以自己修改手机系统时间,所以有时候需要用网络时间而不用系统时间。获取网络标准时间的方法:1、先在需要的地方实现下面的代码,创建一个URL并且连接1 NSURL *url=[NSURL URLWithString:@"http://...
分类:
移动开发 时间:
2015-06-30 19:58:05
阅读次数:
164