ios - 如何在 ios10 中从 WKWebView 获取/存储 cookie?
问题描述
我无法在 ios 10 中从 WKWebView 获取/存储 cookie。您能帮我解决这个问题吗?
解决方案
you can try theses suggestions given in answer. It works for me, i hope it will helpful for you :)
Getting all cookies from WKWebView
also you can try thin in your case [updated]
WKWebsiteDataStore.default().fetchDataRecords(ofTypes: WKWebsiteDataStore.allWebsiteDataTypes()) { records in records.forEach { record in print(record) }
推荐阅读
- android - OkHttp 请求很慢
- javascript - 为什么我在 add 函数中添加 submit 函数时这个程序不起作用?
- php - php 5.4 不支持 CI 会话
- c# - 从 Raspberry Pi 读取光传感器值时出现问题
- javascript - Reactjs 仅在其所有子组件完成渲染时才渲染组件
- kubernetes - 如何在 GKE 上向 istio-sidecar-injector 添加 log_output_level 参数?
- javascript - 我们可以使用相同的按钮来隐藏/显示多个 div
- ruby-on-rails - RSpec/Capybara 找不到图像的链接
- excel - 如何使用 IF AND 宏将单元格复制到另一个工作表?
- javascript - Jquery .each 不适用于表中的第一行