uiwebview

Store UserID From Facebook SDK

可紊 提交于 2019-12-11 19:08:30
问题 How can I store credentials in the Facebook iOS SDK atleast username if not password. I gone through the Facebook iOS SDK ...FBSession which is been need to use login part.but its a Library file ..I cannot see the implementation part .which is [[FBSession activeSession] openWithBehavior:FBSessionLoginBehaviorForcingWebView completionHandler:^(FBSession *session, FBSessionState state, NSError *error) Is it possible to keep credentials? or to hacking a UIWebView to load the facebook login page

XCODE: Unbalanced calls to begin/end appearance transitions for <UIFileUploadFallbackRootViewController

笑着哭i 提交于 2019-12-11 18:52:29
问题 I have in my app a UIWebView, and in that web view I navigate to my mobile site where there is a button input with type 'Choose File' for loading a new profile picture. Each time I try the 'Choose Existing' or 'Take Photo' options from the resulting pull-up iPhone menu, I receive the following error when my View Controller disappears to allow me to choose a photo: "Unbalanced calls to begin/end appearance transitions for UIFileUploadFallbackRootViewController: 0x20d65940" After an image is

Any way to upload image to pinterest with iOS SDK, maybe using a fileURL?

 ̄綄美尐妖づ 提交于 2019-12-11 18:44:30
问题 Hi I'm trying to find a way to post/upload a locally generated image to pinterest with iOS SDK. I'm doing the pinterest integration with UIWebView given that there is no public API and tried to use for the image url a fileURLWithPath: with no success obviously. Does anyone have any idea if this can be accomplished? The pinterest app obviously allows you to upload/pin an image from the camera roll. Is there any way to embed that kind of functionality in my app? Thank you! 回答1: You will need to

Objective C Calling Method on Another Class

半世苍凉 提交于 2019-12-11 18:19:24
问题 I have 2 classes, MainViewController and 'FooView' for example. In MainViewController I have a method called -(void)doSearch I'm trying to call doSearch from Foo, is see in the log "doSearch" (NSLog) but the UIWebView doesn't response. Foo MainViewController *mainVc = [[MainViewController alloc] init]; [mainVc doSearch]; MainViewController - (void)doSearch { NSLog(@"doSearch"); [myWebView loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:@"http://www.google.com/"]]]; } myWebView

UIWebView, mediaPlaybackRequiresUserAction

爱⌒轻易说出口 提交于 2019-12-11 18:18:41
问题 i have a webview that contains a web page, the web page only contains one video and once the web page open the video inside this web page played directly!!, Is this Property ( mediaPlaybackRequiresUserAction ) could helps he out?? i read the documentation but i didnt got the point.. https://developer.apple.com/library/ios/#documentation/UIKit/Reference/UIWebView_Class/Reference/Reference.html#//apple_ref/doc/uid/TP40006950 thnx 回答1: Well mediaPlaybackRequiresUserAction is set to YES by

Embedding Image and UILable in UIWebView

时光毁灭记忆、已成空白 提交于 2019-12-11 18:11:18
问题 I am receiving an image, title and description from a json file and i need to display this on a view. I am using webview because the description attribute has links and is in html format so webview is easiest. However now i need to add the image and title above the description. I know how i can add an image seperately but i dont know how i can add all these three components in the webview. Any help? Thank you NSString * myHTMLImage = @"<img src='Hop.png'>"; NSString *imagePath = [[NSBundle

Open WebView links in Safari

烈酒焚心 提交于 2019-12-11 18:09:08
问题 When Running the app it first loads, then loads the web page in safari. How would I make the page load in the UIWebView and have the external links in the webView open in safari? Here is some of the Code of The webviewcontroller.m - #import "WebViewController.h" @implementation WebViewController @synthesize webView; - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil { if (self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]) { // Initialization code

stringByEvaluatingJavaScriptFromString not return the right value

孤街浪徒 提交于 2019-12-11 17:48:58
问题 [wvPage stringByEvaluatingJavaScriptFromString: @"function getDes(){var attrs = document.getElementsByClassName('description')[0];" "attrs = attrs.getElementsByClassName('table')[0]" "attrs = attrs.getElementsByTagName('li);" "var result='',i;" "for(i=0; i<attrs.length; i++)" "{" " result += attrs[i].getElementsByTagName('span')[0].innerHTML + ':' + attrs[i].getElementsByTagName('p')[1].innerHTML" " if(i+1!=attrs.length)" " result += '|'" "}" "return result;}"]; NSString* attribute_list =

How do I expand the blue highlighted text in UIWebView?

混江龙づ霸主 提交于 2019-12-11 17:39:05
问题 After tap and hold and release, text is highlighted in UIWebView. The user can expand the text by dragging the dots, but is there a way I can automatically do it in code? For example, the user selects "Abraham" and I expand it to be "Abraham Lincoln". 回答1: No. That feature of the UIWebView cannot be modified using Apple-approved public APIs. This also applies to the magnifying glass. 来源: https://stackoverflow.com/questions/4579304/how-do-i-expand-the-blue-highlighted-text-in-uiwebview

iPhone UIWebView Bug

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-11 16:59:45
问题 I am getting this error message in the console, while i am trying to load a html page in UIWebView ? "void SendDelegateMessage(NSInvocation*): delegate failed to return after waiting 10 seconds. main run loop mode: UITrackingRunLoopMode If you were not using the touch screen for this entire interval (which can prolong this wait), please file a bug." Any reason for it ? Thanks 回答1: I don't know if this is necessarily your problem, but I have received the same message when a piece of Javascript