Recommended: ASP instance: ASP implementation space's recent visitors Due to working relationships, we are working on a user space. To use the most recent visitors in the space, see the ASP code: % username=request.QueryString(username) 'The username in the ground column is your username if trim(request.Cookies(user_name)) Then 'The home page needs to determine whether the access is logged in, only logged in can be recorded
When working on a project, I encountered the problem of ASP calling the innocent IP library. Now let me talk about the solution.
<%
' =========================================================
' Return IP information Disp_IPAddressData(IP,0)
' =========================================================
Function Look_Ip(IP)
Dim Wry, IPType, QQWryVersion, IpCounter
' Set the class object
Set Wry = New TQQWry
' Start searching and return to search results
' You can determine whether the IP address exists in the database based on the QQWry(IP) return value. If it does not exist, you can perform some other operations.
'For example, if you build a database for pursuit, I won't explain in detail here
IPType = Wry.QQWry(IP)
' Country: Country: Country Field
' LocalStr: Province, City and other information fields
Look_Ip =Wry.Country & & Wry.LocalStr
'''''Look_Ip = Wry.Country &
End Function
' =========================================================
' Return IP information JS call
' =========================================================
Function Disp_IPAddressData(IP, sType)
Dim Wry, IPType
Set Wry = New TQQWry
IPType = Wry.QQWry(IP)
Select Case sType
Case 1 Disp_IPAddressData = IP
Case 2 Disp_IPAddressData = Wry.Country
Case 3 Disp_IPAddressData = Wry.LocalStr
'Case Else Disp_IPAddressData = Wry.Country & & Wry.LocalStr
Case Else Disp_IPAddressData = Wry.Country
End Select
End Function
' =========================================================
' Return to QQWry information
' =========================================================
Function WryInfo()
Dim Wry, IPType, QQWry_tem(0), QQWry_tem1(1)
' Set the class object
Set Wry = New TQQWry
IPType = Wry.QQWry(255.255.255.254)
' Read database version information
QQWry_tem(0) = Wry.Country & & Wry.LocalStr
' Read the number of database IP addresses
QQWry_tem1(1) = Wry.RecordCount + 1
WryInfo = QQWry_tem(0)& & QQWry_tem1(1)
End Function
Share: ASP prevents GET, Post injection and server attacks, and records IP % 'Prevent GET, Post injection and server attack' Use method to include this file in the file that needs to be noted, so please note that post attacks and Get attacks here are not necessarily attacks. Please pay attention to using them in the English version' Feng Xu modified session.Abandon() Dim fxjt111_Attack_post,fxjt111_Attack_Get,fxjt111_Attack_Sys
4 pages in total Previous page 1234Next page