FunctionurlChk(sUrl)
onerrorresumenext
SetxmlHttp=Server.CreateObject("Microsoft.XMLHTTP")
xmlHttp.open"GET",sUrl,false
xmlHttp.send
ifxmlHttp.Status<>200then
urlChk=false
else
urlChk=true
endif
EndFunction
sUrl="https://www.jb51.net"
ifurlChk(sUrl)then
response.write(sUrl&"(可以正常访问)")
else
response.write(sUrl&"(访问不了)")
endif
