JSOUP可以与LocalStorage值一起使用吗?

发布于 2025-01-23 01:50:22 字数 247 浏览 5 评论 0原文

我正在尝试解析网站(FE Google) 在Chrome本地存储中,我看到变量(键值对) 和文档内容取决于此变量 我可以使用jsoup设置它吗? 还是我应该使用其他工具?

I'm trying parse a website (f.e. google)
In Chrome local storage i see variables (key-value pairs)
And document content depends of this variables
Can i set it using jsoup?
Or I should use other tools for it?
enter image description here

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

ら栖息 2025-01-30 01:50:22

不,您无法使用自己的代码访问Chrome的内容(除非您可以为此找到利用)。您必须使用适当的get发布请求用JSOUP提出的请求,然后独自解析内容。请记住,JSOUP仅加载网站的HTML,因此,如果您的内容是从JS加载的,则必须找到另一种方法来获取它。

No, you cannot access Chrome's content with your own code (unless you can find an exploit for that). You'll have to get the site's content with the proper get or post request made with jsoup and then parse the content by yourself. Just remember that jsoup only loads the HTML of the site, so if your content is loaded from JS, you'll have to find another way to get it.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文