I have a simple quiz page on my website that's setup with Google Adsense Ads.
The ads work fine on the desktop and also in Safari when you type in the URL in Safari on the iOS Device.
I did setup a simple iOS app with a UIWebView
to run the quiz as an app.
The UIWebView
URL is loaded via this code:
if let url = URL(string: "http://itrafikk.net/itrafikkads/") {
webView.loadRequest(URLRequest(url: url))
}
and
func webView(_ webView: UIWebView, shouldStartLoadWith request: URLRequest, navigationType: UIWebViewNavigationType) -> Bool {
if let url = request.url, navigationType == UIWebViewNavigationType.linkClicked {
UIApplication.shared.openURL(url)
return false
}
return true
}
Originally I thought it was an issue with NSAppTransportSecurity
/ NSExceptionDomains
but Google uses an SSL certificate for their Google Ad Services so that shouldn't be the problem.
Any ideas on what might be causing this?