Sunday, 10 November 2019

Itunes app links are not working with WkWebview

One of the webpage I load into Wkwebview has the following iTunes app link

 https://itunes.apple.com/gb/app/xx-yy-zz/id435919263?mt=8

when it's opened I'm getting the following alert

enter image description here

and here's the error that I've got.

{
    "[errorCode]" = 0;
    "[errorDescription]" = "Redirection to URL with a scheme that is not HTTP(S)";
    "[errordetail]" = "Con:myappxxxx:myorder:webview:networkerror";
    "[localizedRecoverySuggestion]" = "";
    "[url]" = "itms-appss://apps.apple.com/gb/app/xx-yy-zz/id435919263";
}

When the same iTunes link ( https://itunes.apple.com/gb/app/xx-yy-zz/id435919263?mt=8 ) is opened in UIWebview , I saw that URL gets redirected to following URL and app opens in appstore

 itms-appss://itunes.apple.com/gb/app/xx-yy-zz/id435919263?mt=8

Whereas in Wkwebview , the URL gets redirected to following URL

 itms-appss://apps.apple.com/gb/app/xx-yy-zz/id435919263

Any help is appreciated


Update

I even tried Arbitrary uploads to true for transport security and the problem is still there.

Error Domain= Code=0 "Redirection to URL with a scheme that is not HTTP(S)" UserInfo={_WKRecoveryAttempterErrorKey=, NSErrorFailingURLStringKey=itms-appss://apps.apple.com/gb/app/xx-yy-zz/id435919263, NSErrorFailingURLKey=itms-appss://apps.apple.com/gb/app/xx-yy-zz/id435919263, NSLocalizedDescription=Redirection to URL with a scheme that is not HTTP(S)}



from Itunes app links are not working with WkWebview

No comments:

Post a Comment