开发者

Get link position on screen from google search results

I want to make an app in .net to search on google for a keyword and click on a specific lin开发者_运维技巧k from the results. Like a bot.

How can I get the coordinates of screen where the specific link appears in search results so I can do a click on it. The component where the page loads will have javascript enabled so just parsing the html is not enought. It must look like a real user is clicking on the link.( it`s for a school project involving seo)

or What is the best approach to do this ?


Wouldn't it be much easier to get a reference to the DOM element and simulate a click on that, instead of playing around screen coordinates?


Why do you need the actual coordinates? If you are triyng to do this in C#, just get the HTML back from Google, and look through it to see how many results down the link is, wouldn't this be sufficient?? Screen coordinates does not seem very reliable (may differ for different people I think?)

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜