它保存成文件(后缀名为vbs)后双击运行就行了
on error resume Next Dim a
a = True set WshShell = WScript.CreateObject("WScript.Shell") Do While a
set http = CreateObject("Microsoft.XMLHTTP")
http.open "POST","http://你网站的页面地址",false
http.send
if http.Status > 300 then
WshShell.Run("net stop tomcat5")
WScript.Sleep(10000)
WshShell.Run("net start tomcat5")
end if
WScript.Sleep(30000)
loop
on error resume Next Dim a
a = True set WshShell = WScript.CreateObject("WScript.Shell") Do While a
set http = CreateObject("Microsoft.XMLHTTP")
http.open "POST","http://你网站的页面地址",false
http.send
if http.Status > 300 then
WshShell.Run("net stop tomcat5")
WScript.Sleep(10000)
WshShell.Run("net start tomcat5")
end if
WScript.Sleep(30000)
loop
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货