ios6 - UIWebview in iOS 6 - To load the content using loadData method -
i have tried load content(docx,xlxx,.m,.h , etc except images&pdf) in ios6-uiwebview using loaddata method. the content not loading.
incase utilize loadrequest , content getting loaded. but, loaddata method working fine ios 7 , above.
i sending mime type correctly.
kindly clarify me, possible load content in uiwebview using loaddata method in ios 6?
thanks in advance.
use code document viewing in webview
nsurl *url = [[nsurl alloc] initfileurlwithpath:[[nsbundle mainbundle] pathforresource:@"{file name}" oftype:@"{file type}"]]; nsurlrequest *request = [nsurlrequest requestwithurl:url]; uiwebview *webview = [[uiwebview alloc] initwithframe:cgrectmake(0, 0, self.view.frame.size.width, self.view.frame.size.height)]; [self.view addsubview:webview];
ios ios6 uiwebview
No comments:
Post a Comment