//获取网页html
NSURL* url = [NSURL URLWithString:@"http://www.baidu.com"];
NSMutableURLRequest* request = [NSMutableURLRequest new];
[request setURL:url];
[request setHTTPMethod:@"GET"];
NSURLRequest* response;
NSData* data = [NSURLConnection sendSynchronousRequest:request
returningResponse:&response error:nil];
NSString* strRet = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding];
NSLog(strRet);
[strRet release];