注册 登录
编程论坛 ASP技术论坛

请教两个问题百度快照和PR获取方法

danhaoran 发布于 2010-10-22 15:08, 1066 次点击
请教两个问题百度快照和PR获取方法

最好是代码表现,怎么样的获取到百度快照的时间.
6 回复
#2
zmh8862010-10-23 12:05
xmlhttp获取百度搜索页源码 然后提取时间
#3
danhaoran2010-10-25 09:10
具体怎么去做啊?求问!
#4
sunlinlin1232010-10-25 14:33
<%Server.ScriptTimeOut=9999999
Function GetHTTPPage(HttpUrl,param)
dim XmlHttp
set XmlHttp=Server.createobject("Microsoft.XMLHTTP")
XmlHttp.open "Get",HttpUrl,false
XmlHttp.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
XmlHttp.send param
if XmlHttp.readystate<>4 then
   exit function
end if
'GetHTTPPage=bytesToBSTR(XmlHttp.responseText,"GB2312")'若取得页面BODY内容用此方法。
GetHTTPPage=XmlHttp.responseText
set XmlHttp=nothing
if err.number<>0 then
   err.Clear
end if
End Function

Function BytesToBstr(Body,Cset)
    Dim Objstream
    Set Objstream = Server.CreateObject("adodb.stream")
    objstream.Type = 1
    objstream.Mode =3
    objstream.Open
    objstream.Write body
    objstream.Position = 0
    objstream.Type = 2
    objstream.Charset = Cset
    BytesToBstr = objstream.ReadText
    objstream.Close
    set objstream = nothing
End Function
url="http://www.
str=GetHTTPPage(url,param)
response.write str
%>
#5
danhaoran2010-10-26 09:10
我要传参数进去,就是传一个网站地址,怎么获取百度快照时间?
#6
danhaoran2010-10-26 10:43
哈哈,稿定了,谢谢哥们!
#7
bccn20132012-09-19 08:50
回复 6楼 danhaoran
请赐教,先谢过高手!
1