开发者

iphone read txt file from UIWebView

I can read the data in file.txt file located in local disk.

NSString *filePath = [[NSBundle mainBundle] pathForResource:@"file" ofType:@"txt"];
NSString* 开发者_StackOverflow社区Data = [NSString stringWithContentsOfFile:filePath encoding:NSUTF8StringEncoding error:&error ];

now, I upload the file.txt file into a website. how can i read the data from the txt file now from UIWebView?

Please help!!


The similar way:

NSString* Data = [NSString stringWithContentsOfURL:fileURL usedEncoding:NSUTF8StringEncoding error:&error ];
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜