Getting all cookies from WKWebView

Cookies used (created) by the WKWebView are actually correctly stored in the NSHTTPCookieStorage.sharedHTTPCookieStorage(). The problem is that the WKWebView does not write back the cookies immediately. I think it does this on its own schedule. For example when a WKWebView is closed or maybe periodically. So eventually they do end up in there, but when … Read more

How to display .svg image using swift

There is no Inbuilt support for SVG in Swift. So we need to use other libraries. The simple SVG libraries in swift are : 1) SwiftSVG Library It gives you more option to Import as UIView, CAShapeLayer, Path, etc To modify your SVG Color and Import as UIImage you can use my extension codes for … Read more

Load local html into UIWebView using swift

To retrieve URLs for application resources, you should use URLForResource method of NSBundle class. Swift 2 let url = NSBundle.mainBundle().URLForResource(“privacy”, withExtension:”html”) Swift 3 let url = Bundle.main.url(forResource: “privacy”, withExtension: “html”)

What does Unrestricted Web Access mean in iTunes Connect

It means that a user of the app can access any URL. The issue is parental controls. If the parent has restricted web access an app that allows unlimited access, that is access to any site the user chooses then the parental controls are subverted. Once Apple provided parental controls that caused a ripple effect … Read more

Javascript console.log() in an iOS UIWebView

After consulting with an esteemed colleague today he alerted me to the Safari Developer Toolkit, and how this can be connected to UIWebViews in the iOS Simulator for console output (and debugging!). Steps: Open Safari Preferences -> “Advanced” tab -> enable checkbox “Show Develop menu in menu bar” Start app with UIWebView in iOS Simulator … Read more

iOS 7 Status bar with Phonegap

I found an answer on another thread, but I’ll answer the question in case someone else wonders. Just replace the viewWillAppear in MainViewController.m with this: – (void)viewWillAppear:(BOOL)animated { // View defaults to full size. If you want to customize the view’s size, or its subviews (e.g. webView), // you can do so here. // Lower … Read more

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