<%
Function urlChk(sUrl)
on error resume next
Set xmlHttp = Server.CreateObject("Microsoft.XMLhttp")
XMLHttp.open "GET",sUrl,false
XMLHttp.send
if XMLHttp.Status <> 200 then
urlChk=false
else
urlChk=true
end if
End Function
sUrl="http://code.dlstu.cn"
if urlChk(sUrl) then
response.write(sUrl&"(可以正常訪問!)")
else
response.write(sUrl&"(頁面打開錯誤!)")
end if
%>