使用屏幕截图提取数据

发布于 2024-08-18 07:46:10 字数 1536 浏览 1 评论 0原文

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

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

发布评论

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

评论(1

皓月长歌 2024-08-25 07:46:10

自己写——这并不难。如果您不熟悉编程或可以选择编程语言:使用 Python 库支持来进行出色的抓取。

至于如何解决这个问题,有两种流行的技术:使用正则表达式,效果最好用于临时屏幕抓取。如果您的目标网站结构良好 - 请阅读:不是临时的 - 然后使用一个允许您使用 DOM

导航和提取

这是编写spider的两个阶段。您的蜘蛛需要导航网站以访问不同的页面,并且需要提取感兴趣的信息。这两个阶段都可以由 DOM 或 RE 的

p.s. 驱动,因为你的名字表示 .NET ——我应该提到我已经用 C-Sharp 编写了 scrapers ——这是轻而易举的事。

Write your own -- it isn't hard. if you aren't familiar with programming or have a choice for programming languages: use Python the library support for doing scraping great.

As for how to attack the problem their are two popular techniques: use regular expressions, they work best for ad-hoc screen scraping. If your target web-sites are well structured -- read: not ad-hoc -- then use a framework that allows you to work with the DOM.

Navigation and Extraction

These are the two phases of writing a spider. Your spider needs to navigate a website to visit different pages, and it needs to extract information of interest. Both these phases can be driven by either the DOM or RE's

p.s., Since your name indicates .NET -- I should mention that I have written scrapers in C-Sharp -- it's a doddle.

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