Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

the Location Service not working with UIWebView in iOS10

Tags:

My app has an UIWebView to use Location Service via HTML5. It works fine below iOS 10. When you first launch the app, and get to the webView, then an alert appears to ask use's allowance of system Location Service. Under your permission, the UIWebView does it's work. Everything feels awesome.

However, when I installed my app to an device running iOS10, the alert doesn't show up. And the UIWebView shows an error. I even cannot find location settings in the Settings app.

Does any body get the same problem? Or could anyone tell me what happened? Any clue will be appreciated.

like image 934
Neal.Marlin Avatar asked Sep 23 '16 05:09

Neal.Marlin


1 Answers

I can't find anything specific to UIWebView, however, I have seen that apple is now blocking calls to the geolocation API on insecure pages.

Web APIs

Started blocking Geolocation API calls on pages served over insecure connections

See release notes

I suspect your problem is related to this.

like image 175
Cloud9999Strife Avatar answered Sep 23 '22 16:09

Cloud9999Strife