欢迎光临
我们一直在努力

命令行方式读取WEB页面

建站超值云服务器,限时71元/月

view-webrun.vbs

dim url, oargs  
2  
3 set oargs = wscript.arguments  
4  
5 if oargs.count = 0 then  
6 msgbox("错误:必须有url")  
7 wscript.quit 1  
8 end if  
9  
10 url = oargs(0)  
11  
12 on error resume next  
13 set objxml = createobject("msxml2.serverxmlhttp")  
14  
15 if err then  
16 msgbox("error: " & err.description)  
17 wscript.quit 1  
18 end if  
19  
20 连接远程机器并取回页面内容
21 objxml.open "get", url, false  
22  
23 objxml.send()  
24  
25 返回结果
26 msgbox objxml.responsetext  
27  
28 清场
29 set objxml = nothing  

赞(0)
版权申明:本站文章部分自网络,如有侵权,请联系:west999com@outlook.com 特别注意:本站所有转载文章言论不代表本站观点! 本站所提供的图片等素材,版权归原作者所有,如需使用,请与原作者联系。未经允许不得转载:IDC资讯中心 » 命令行方式读取WEB页面
分享到: 更多 (0)