开发者

How do I check if a page is Google cached in Perl?

I tried lots of modules, seems like nothing works 开发者_运维技巧well. Do you have any idea how to check if a page I supply, for example: http://bloggingheads.tv/forum/member.php?u=12129

Is available on google cache? I'm using Perl.


Try connecting to

http://www.google.com/search?q=incache:[url]

(Note that the URL should be URL-encoded)

For example:

http://www.google.com/search?q=incache%3Ahttp%3A%2F%2Fbloggingheads.tv%2Fforum%2Fmember.php%3Fu%3D12129

If your page is stored in the Google cache, you will have a search result. If the page isn't, you will have a text saying "Your search did not match any document".

You can try to parse this page to know if your page is in the Google cache.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜