我目前通过托管运行正常的 Apache http 服务器解析托管在另一台 PC 上的 xml 文件。现在是否可以以 iPhone 删除该 pc 上的 xml 文件的方式对其进行编码?
我目前使用 NSMutableURLRequest 并将其设置为 NSData。
NSError * error;
NSURLResponse * response;
NSMutableURLRequest *request =
[NSMutableURLRequest requestWithURL:[NSURL URLWithString:@"http://ipaddress/UserBedData.xml"]
cachePolicy:NSURLRequestReloadIgnoringCacheData
timeoutInterval:5.0];
[request setHTTPMethod:@"GET"];
NSData * responseData = [NSURLConnection sendSynchronousRequest:request
returningResponse:&response
error:&error];
xmlParser = [[NSXMLParser alloc] initWithData:responseData];