Tips | Refresh Force Refresh Web page
<%
' Mandatory refresh random verification code
' Let the Random verification code press the IE's back button each time, returns the login page the immediately code all automatically refreshes,
Response.expires=-1
Response.AddHeader "Pragma", "No-cache"
Response.AddHeader "Cache-control", "No-store"
%>
Determine if the file address is valid
<%
' Original author: Xiao Yi qq:52093 time: 2005.6.30
Response.Write ("On Error Resume Next
Dim Thisurl,thistext
Thisurl=request ("Thisurl") ' defines the file address (non-HTML format document)!
If Thisurl= "" Then
Response.Write ("<span> Please enter the file address!</span> first")
Response.End
End If
Function objXmlHttp (XmlUrl)
On Error Resume Next
Set Objxml = CreateObject ("Microsoft.XMLHTTP")
Objxml. Open "Get", Xmlurl,false
Objxml.setrequestheader "Content-type", "application/x-www-form-urlencoded"
Objxml.send
objXmlHttp = Objxml.responsebody
If Err Then
Err.Clear
Response.Write ("<span> failed to establish connection, file does not exist or network problem!; Error reason: "&Err.Description&"! </span> ")
Response.End
End If
End Function
Function Bytes2bstr (vIn)
Strreturn = ""
For i = 1 to LenB (vIn)
Thischarcode = AscB (MidB (vin,i,1))
If Thischarcode < &h80 Then
Strreturn = Strreturn & Chr (Thischarcode)
Else
Nextcharcode = AscB (MidB (vin,i+1,1))
Strreturn = Strreturn & Chr (CLng (thischarcode) * &h100 + CInt (nextcharcode))
i = i + 1
End If
Next
Bytes2bstr = Strreturn
End Function
Thisurl2=split (Thisurl, ",")
For all II in THISURL2
Thistext=bytes2bstr (objXmlHttp (ii))
If InStr (Thistext, "Response.Write ("<span>" & II & "<b>x</b></span><br>")
Else
Response.Write ("<span>" & II & "<b>√</b></span><br>")
End If
Next
If Err Then
Err.Clear
Response.Write ("<span> encountered an accident!; Error reason: "&Err.Description&"! </span> ")
Response.End
End If
%>