如何从锚标记的网址中删除数据? [英] How to scrap the data from the url of the anchor tag?

查看:94
本文介绍了如何从锚标记的网址中删除数据?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个打开页面的网址现在页面包含很少的锚标签,其中一个是老师,

现在我想从该锚标签中删除教师详细信息。

假设我现在给了你的网址www.html.com打开一个网站,它包含一个锚标签

。现在我想从www.teacher.com废弃老师的详细信息

但是作为一个inout我有www.html.com。

怎么办?

I have a url which open a page now the page contains few anchor tags and one of them is teacher,
Now i want to scrap the teacher details from that anchor tag.
Suppose i gave u a url name www.html.com now that opens a website and it contains an anchor tag
.Now i want to scrap details of teacher from www.teacher.com
but as an inout i have www.html.com.
How could it be done?

推荐答案

如果您已下载HTML,请使用 HtmlAgilityPack [ ^ ]检索感兴趣的属性。
If you have the HTML downloaded, use HtmlAgilityPack[^] to retrieve the attributes of interest.


你可以使用下面的链接下载html源代码,并可以在div层显示它。



http://msdn.microsoft.com/en-u s / library / system.net.webrequest.aspx [ ^ ]





谢谢
You can download the html source code using the below link and can show it on the div layer.

http://msdn.microsoft.com/en-us/library/system.net.webrequest.aspx[^]


Thanks


这篇关于如何从锚标记的网址中删除数据?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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