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://www.uoften.com"
if urlChk(sUrl) then
response.write(sUrl&"(可以正常访问)")
else
response.write(sUrl&"(访问不了)")
end if
最后
以上就是超级芝麻最近收集整理的关于asp下的一个检测链接是否正常的函数的全部内容,更多相关asp下内容请搜索靠谱客的其他文章。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复