当前位置:编程学习 > wap >>

wp开发中利用xpath获取html内容的问题

 pp.Text = cc.DocumentNode.SelectSingleNode("//meta[@name='description']/@content").InnerText;

获取节点meta中 属性“name”为description的节点,得到该节点的content属性 ,该语法有问题么?
为什么调试得不到内容。。 Windows Phone HTML XPath --------------------编程问答-------------------- 你用的是什么类库?
htmlagile? --------------------编程问答--------------------
引用 1 楼 cuit 的回复:
你用的是什么类库?
htmlagile?
   

HtmlAgilityPack   譬如 对于片段<div class="pic"><img width="192" src="http://t2.qpic.cn/mblogpic/93e0cbbd6a50202164f0/460" />

 用   "//div[@class='pic']/img/@src")   获取src的属性内容,为什么不行啊 。。。。
补充:移动开发 ,  Windows Phone
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,