ITMS-90809: Deprecated API Usage — Apple will stop accepting submissions of apps that use UIWebView APIs

Check if you use in your code the UIWebView class; if yes replace your implementation with WKWebView, else need check your Pods. Go with terminal into your project folder and execute the command: grep -r “UIWebView” . All matched pod must be updated. Now I’m stuck because I found UIWebView into Google AdMob (version 7.49.0) … Read more

iOS JavaScript bridge

There are a few libraries, but I didn’t used any of these in big projects, so you might want to try them out: WebViewJavascriptBridge: https://github.com/marcuswestin/WebViewJavascriptBridge GAJavaScript: https://github.com/newyankeecodeshop/GAJavaScript — However, I think it’s something simple enough that you might give it a try yourself. I personally did exactly this when I needed to do that. You … Read more

Can we open pdf file using UIWebView on iOS?

Yes, this can be done with the UIWebView. If you are trying to display a PDF file residing on a server somewhere, you can simply load it in your web view directly: Objective-C UIWebView *webView = [[UIWebView alloc] initWithFrame:CGRectMake(10, 10, 200, 200)]; NSURL *targetURL = [NSURL URLWithString:@”https://www.example.com/document.pdf”]; NSURLRequest *request = [NSURLRequest requestWithURL:targetURL]; [webView loadRequest:request]; [self.view … Read more

How to make a transparent UIWebView

I recommend: webView.opaque = NO; webView.backgroundColor = [UIColor clearColor]; (setting these properties in Interface Builder will work for iOS 5.0+, but for iOS 4.3 you must set the backgroundColor in code) And include this into your HTML code: <body style=”background-color: transparent;”>

Load resources from relative path using local html in uiwebview

This is how to load/use a local html with relative references. Drag the resource into your xcode project (I dragged a folder named www from my finder window), you will get two options “create groups for any added folders” and “create folders references for any added folders”. Select the “create folder references..” option. Use the … Read more

Disabling user selection in UIWebView

Here are a few ways to disable selection: Add the following to your mobile web documents <style type=”text/css”> * { -webkit-touch-callout: none; -webkit-user-select: none; /* Disable selection/copy in UIWebView */ } </style> Programmatically load the following Javascript code: NSString * jsCallBack = @”window.getSelection().removeAllRanges();”; [webView stringByEvaluatingJavaScriptFromString:jsCallBack]; Disable the Copy / Paste user menu: – (BOOL)canPerformAction:(SEL)action withSender:(id)sender … Read more

Migrating from UIWebView to WKWebView

UIWebView => WKWebView Equivalent UIWebViewDelegate => WKNavigationDelegate delegate => navigationDelegate didFailLoadWithError => didFailNavigation webViewDidFinishLoad => didFinishNavigation webViewDidStartLoad => didStartProvisionalNavigation shouldStartLoadWithRequest => decidePolicyForNavigationAction About shouldStartLoadWithRequest you can write: func webView(_ webView: WKWebView, decidePolicyFor navigationAction: WKNavigationAction, decisionHandler: @escaping (WKNavigationActionPolicy) -> Void) { print(“webView:\(webView) decidePolicyForNavigationAction:\(navigationAction) decisionHandler:\(decisionHandler)”) switch navigationAction.navigationType { case .linkActivated: if navigationAction.targetFrame == nil { self.webView?.loadRequest(navigationAction.request) } … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)