如何在webview之后返回应用程序?

问题描述 投票:0回答:1

应用程序流程要求用户访问网页并更新一些细节,之后用户需要返回网站提供的ID。

蛋情景:

User logs in application 
  clicks button goes to the website update few details 
  stays in the Webview for the website

必需的场景:

Should come back to the app with the id that website provided 

该应用程序的流程类似于谷歌Oauth,用户点击谷歌按钮来验证谷歌使用谷歌帐户。

ios swift uiwebview stripe-connect
1个回答
0
投票

您可以在WKWebView中显示该网页。假设您也正在编写​​网页编码,您还可以使用evaluateJavaScript(:completionHandler:)来确定网站何时完成,获取结果并调整WKWebView。或者,您可以使用WKNAvigationDelegate方法webView(:didStartProvisionalNavigation:)拦截成功导航,然后从服务器获取所需的任何信息。

© www.soinside.com 2019 - 2024. All rights reserved.