首页 > 其他 > 详细

get_hotnews_no1_from_baidu

时间:2014-12-14 07:09:36      阅读:273      评论:0      收藏:0      [点我收藏+]
$ie = new-object -com "InternetExplorer.Application"
$ie.navigate("http://www.news.baidu.com/")
$ie.visible = $true
sleep -milliseconds 2500

$ID = $ie.Document.getElementById(‘focus-top‘)
$ID1 = $ID.getElementsByTagName(‘li‘)
$ID2 = $ID1 | where {$_.className -contains "hdline0"}
$ID2.innerText


get_hotnews_no1_from_baidu

原文:http://6124856.blog.51cto.com/6114856/1589632

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!