Support file downloading in WKWebView


I have a simple app to show web application in WKWebView.

The main problem is when the user clicks the link to download file then the WKWebView is trying to display this file instead of download.

Is it possible to implement somehow the possibility to download the file when users clics the link to this file?

The link to file doesn’t include a file name in URL (for example: http://domain/rest/getFile).


I have implemented method “decidePolicyForNavigationAction” but then I don’t know how to download this file by URL.




Powered by WPeMatico

You may also like...

Comments are closed.