Open WebView URL in Browser

后端 未结 2 1121
傲寒
傲寒 2021-01-15 01:54

I made a very simple Swift application that loads a webpage with links on it. Whenever I click the links, they do not open. How would I got about having the links on the loa

2条回答
  •  有刺的猬
    2021-01-15 02:33

    Also you can decide what links to open in WebView and what - in browser as easy as to write target attribute in your html page like

    external page
    

    And use target check in the decidePolicyForNewWindowAction, menthioned above. I've placed the full answer in this question thread. Hope you can translate it to swift yourself.

提交回复
热议问题