Apple iOS Safari Extension Permission - ios

I've developed a Safari Extension for iOS and in order to use that extension, it needs to enable the permission from Safari Settings in the Settings screen. I need to know whether there is a nice way to allow the user to allow permission. Is there any way that I can enable the permissions directly from my Safari Extension iOS app so that the user doesn't get confused and end up not allowing the permission. Or if I can navigate the user to the permission screen in Settings directly? Anyone who can help me here?

The user can also give permission to the extension from Safari, without having to navigate to the settings. Like that: https://www.joinhoney.com/en/mobile/ext/enable/ (Must open on iOS safari)

Related

How to force to open app by Universal Link in Swift likes iOS Notes app

I run into an issue with Universal Link that once the Universal Link is opened by Safari, it won't able to open by its app.
Seem iOS does remember the last app used to open the link.
But when I copy the link into iOS Notes app, long-press, select Open in "App Name" and the issue is gone! (Check the screenshot)
Does anybody know how to force to open an app like iOS Notes app?
Or does anybody know how to check whether the URL has been remembered to open by Safari by iOS?
I did try by open(_:options:completionHandler:) & specific options [.universalLinksOnly: true] but it doesn't work
Thanks all 🙏🏿
This article may help.
When a user browses your website in Safari and taps a universal link in the same domain, the system opens that link in Safari, respecting the user’s most likely intent to continue within the browser. If the user taps a universal link in a different domain, the system opens the link in your app.

Camera and Photos permission - iOS [duplicate]

In my iOS app I am accessing the user's photo gallery. The first time the user does this, it asks them for permission. Some of my users have reported getting a crash this first time due to the permission request, but it works fine on subsequent tries.
To be able to test this on my own, I need to be able remove the permission from my iPad and have it prompt again. Is there a way to do this either through the iPad/iPhone itself or through code?
Run the Settings app. Go to General, then Reset. Tap on Reset Location & Privacy. This will reset all of your location and privacy settings, not just for your test app. But you are doing this on a development device so that should be OK. This works in the Simulator too.
In iOS 7+, you can go into Settings > Privacy > Photos and explicitly enable or disable access for individual apps.
This is much better than resetting your entire device privacy settings!
Another way is to temporary change Bundle Identifier (CFBundleIdentifier) in Info.plist.
System will treat such app as a new separate app and will display "would like to access your Photos" alert.
Don't forget to revert CFBundleIdentifier after you end testing.

How to handle "don't allow" permission in iMessage extension?

I am developing one iMessage Extension in which I need to use photos from Photo Library, but here it generated one use case for which I am not getting any solution.
When OS ask for Photo permission access to user, then user set Don't allow, after that how to set permission on for iMessage Extension.
But I am not able to find settings menu for iMessage Extension app from which user set photo permission on.
NOTE: I am developing iMessage Extension without parent iOS App.
You can enable this permission later from privacy setting. Please check below path to enable that permission
Settings -> Privacy -> Photos -> < Your app >

Open in [MyAppName] from WKWebView

Can I achieve the Open in [MyAppName] banner using a WKWebView?
Open in MyAppName
I have submitted an app [written in Swift] which prompts the user to sign in to a google account through Safari and open a .csv file of a report. When the report is opened the user is presented with the Open in [MyAppName] banner. They click it, the app launches with the contents of the URL and it all works perfectly.
Apple have rejected the app saying that navigating the user to Safari is a 'poor user experience' and suggest I use a Safari View Controller. As this is available for iOS9+ and I want to target iOS8+ I am looking to use a WKWebView but I can't seem to get the Open in [MyAppName] banner to appear. I'm not aware that this functionality is even possible with WKWebView.
I've messaged Apple to ask them but I find them so slow to reply.
Thanks in advance
Steve

How to open device settings app not the app settings programmatically in iOS 8.0+

I am working on an app in which I need to open the device settings app on button client rather than app settings. I am using UIApplicationOpenSettingsURLString - but this opens the app settings page not the root level for device settings.
So, may I please get some suggestions on how to open the device settings app and may I also know is there any possibility to open the wi-fi settings page in the device settings programmatically.
You con only open the app-settings as you mentioned above.
If it would would it would also be listed in the documentation:
https://developer.apple.com/library/ios/documentation/UIKit/Reference/UIApplication_Class/#//apple_ref/doc/constant_group/Settings_Launch_URL
Even Apps like GoPro or Twitter just give instructions how to enter the settings rather then linking directly.

Resources