更改网站布局后请勿破坏屏幕抓取 [英] Don't break the screen scraping after changing the layout of the website

查看:69
本文介绍了更改网站布局后请勿破坏屏幕抓取的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我正在使用C#.net进行屏幕抓取.我可以编写用于在网站上抓取信息的屏幕抓取程序. 但是如果网站的布局将被更改,则屏幕抓取程序将不再起作用. (更改网站布局后,抓取将被中断).

那么,谁能告诉我该问题的解决方案是什么?

谢谢
Harish Kumar

Hi,

I am using the C#.net for screen scrapping. I am able to write the screen scrap program for scrapping information on website. But if the layout of the website will be changed, the screen scrap program will not longer be work. (the scraping will be break''d after changing the layout of the website).

So, can anyone tell me what is the solution of this problem?

Thank You
Harish Kumar

推荐答案

无法阻止这种情况的发生.您可以通过使用ID(如果已分配ID)来缓解这种情况,但即使如此,它也可能会随着网站编码者的兴致而改变.从本质上讲,您被搞砸了,对此您无能为力,expet试图跟上变化,并希望它们不会经常发生.
There is no way to prevent this from happening. You can mitigate it by using IDs (if they''re assigned), but even that could change at the whim of the web site''s coder. In essence, you''re screwed and there''s nothing you can do about it excpet try to keep up with the changes and hope they don''t happen too often.


@约翰:好吧!但是如果网站的布局将被更改,是否可以接收到自动警报提示该网站将被更改.
@John: okay! but if the layout of the website will be changed, can it is possible to receive an automatically alert shows that the website will be changed.


这篇关于更改网站布局后请勿破坏屏幕抓取的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆