WebView signature iOS - WKWebView
Tuesday, May 26, 2020 at 01:42pmHello, I am implementing signature for an iOs application, I am showing with WKWebView.
but I don't know how to hide or close this WKWebView when the user has finished signing. used WKWebView delegates, but when you go from the signature view to the "Thank you" view, not call none this delegates
How can I know when the user has signed and can close the webView.?
func webView(_ webView: WKWebView, didFinish navigation: WKNavigation!) {
print("finish to load")
}
func webView(_ webView: WKWebView, didStartProvisionalNavigation navigation: WKNavigation!) {
print("Start to load")
}
func webView(_ webView: WKWebView, runJavaScriptAlertPanelWithMessage message: String, initiatedByFrame frame: WKFrameInfo, completionHandler: @escaping () -> Void) {
print("text")
completionHandler()
}
func webView(_ webView: WKWebView, decidePolicyFor navigationAction: WKNavigationAction, decisionHandler: @escaping (WKNavigationActionPolicy) -> Void) {
print("text 2")
decisionHandler(.allow)
}
func webView(_ webView: WKWebView, createWebViewWith configuration: WKWebViewConfiguration, for navigationAction: WKNavigationAction, windowFeatures: WKWindowFeatures) -> WKWebView? {
print("text 3")
return nil
}
Reply to: WebView signature iOS - WKWebView
Tuesday, May 26, 2020 at 02:55pmHi josetovar14,
I believe you are rendering the HTML (loading Signing Ceremony URL) in a WebView versus using our native iOS SDK, right? In this case, you might need to create your own HTML and embed the Signing Ceremony into an iFrame (maybe a full screen iFrame), so that you can use the javascript notifier to monitor the signing process, then make post to your WebView controller.
For embedding Signing Ceremony into an iFrame and loaded from WebView, check this code share.
Duo
Reply to: WebView signature iOS - WKWebView
Tuesday, May 26, 2020 at 05:25pmit worked, Thanks a lot... I imagine that for Android it is the same? there is Sample on Android Demo.. ?