Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to open URL schemes from Safari in iOS9?

I was able to open apps from safari this way:

window.location = 'myapp://do/xx';

or open facebook app:

window.location = 'fb://';

But this stopped working in iOS9.

How can I open apps using URL schemes in safari?

like image 519
kevin Avatar asked Jul 11 '15 20:07

kevin


People also ask

How do I get iOS URL scheme?

Finding an App's Main URL Scheme Name First, you have to download the IPA file for the app, which requires macOS and Apple Configurator 2. When you finally find the IPA, you have to turn it into a ZIP file, show the contents of the app package, then hunt for the specific PLIST file that contains the scheme names.

How do I find and use iOS URL schemes for shortcuts?

Open a specific shortcut using a URL scheme You can launch the app to a particular shortcut in your collection. Open a URL with the following structure: shortcuts://open-shortcut?name=[name] , and provide the name of the shortcut in the name parameter.


1 Answers

IOS 9 URL Shchemes Update : iOS 9 introduces LSApplicationQueriesSchemes to allow apps to query if other apps are installed.

1- If a url scheme is declared and calling canOpenURL(scheme)

YES if a installed app supports that URL scheme

NO if no app supporting that url

syslog will show canOpenURL: failed for URL: "urlScheme://" - error: null

2- If a url scheme is not declared and calling canOpenURL(scheme)

always return NO

syslog will show canOpenURL: failed for URL: "urlScheme://" - error: null

In iOS 9, the developer must add these info.plist LSApplicationQueriesSchemes

<array>
    <string>urlscheme</string>
    <string>urlscheme2</string>
    <string>urlscheme3</string>
    <string>urlscheme4</string>
</array>

50 max. unqiue URL scheme can be declared!

like image 176
Malek Belkahla Avatar answered Oct 07 '22 22:10

Malek Belkahla