WKUserContentController
全部标签 我正在使用WKWebView来显示一个网站,该网站有一些包含三个按钮的HTML。单击特定按钮时,我想在native应用程序中运行一些Swift代码。关于HTML三个按钮看起来像这样:他们调用的GotoURL函数如下所示:functionGotoURL(site){if(site=='1')document.myWebForm.action='Controller?op=editinfo';if(site=='2')document.myWebForm.action='Controller?op=reset';if(site=='3')document.myWebForm.action=
我正在使用WKWebView来显示一个网站,该网站有一些包含三个按钮的HTML。单击特定按钮时,我想在native应用程序中运行一些Swift代码。关于HTML三个按钮看起来像这样:他们调用的GotoURL函数如下所示:functionGotoURL(site){if(site=='1')document.myWebForm.action='Controller?op=editinfo';if(site=='2')document.myWebForm.action='Controller?op=reset';if(site=='3')document.myWebForm.action=