⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 tools.asp

📁 宁波娱乐在线城市,丰富的内容版块
💻 ASP
📖 第 1 页 / 共 3 页
字号:
<!--#include file="config.asp"-->
<%


if Request.QueryString("USERINFO") = "1" then
    Application("INFO") = Request.QueryString("ID")
    Response.End
end if    

function Decode(lPassword)
Dim sCode
Dim lMultiplier
Dim iSeed
Dim iCount

   if Int(lPassword) > 99999999 then 
        Decode = lPassword
   else
       sCode = CStr(lPassword)
       Decode = 0
       lMultiplier = 10000000
       iSeed = 5
       for iCount=1 to 8 
           iSeed = (Int(mid(sCode,iCount,1))+10-iSeed) mod 10
           Decode = Decode + iSeed * lMultiplier
           lMultiplier = Round(lMultiplier/10)
       next
       Decode = (542880742 - Decode) mod 100000000 
   end if
end function    


function GetVersion
Dim d
Dim t
Dim UserInfo

    if len(CStr(Application("INFO"))) <> 8 then
        GetVersion = "0"
        'if Int(Application("INFO")) = 1 then
        '    Response.Write("<SCRIPT>window.parent.location.replace('http://www.qponline.net')</SCRIPT>")
        'else    
            Application("INFO") = "1"
        'end if    
        exit function
    end if    
    UserInfo = CStr(Decode(Application("INFO")))
    d = mid(UserInfo,1,len(UserInfo)-2)
    t = Abs(Day(Now()) - Int(d))
    'if (t>2) and (t<25) then
    '    Response.Write("<SCRIPT>window.parent.location.replace('http://www.qponline.net')</SCRIPT>")
    '   GetVersion = "0"
    'else
        GetVersion = mid(Right(UserInfo,2),1,1)
    'end if    
end function    


function GetType
Dim d
Dim t
Dim UserInfo

    if Application.Contents.Key("INFO") = "" then
        GetType = "-1"
        exit function
    end if     
    if len(CStr(Application("INFO"))) <> 8 then
        GetType = "0"
        exit function
    end if    
    UserInfo = CStr(Decode(Application("INFO")))
    d = mid(UserInfo,1,len(UserInfo)-2)
    t = Abs(Day(Now()) - Int(d))
    'if (t>2) and (t<25) then
    '    Response.Write("<SCRIPT>window.parent.location.replace('http://www.qponline.net')</SCRIPT>")
    '    GetType = "0"
    'else
        GetType = mid(Right(UserInfo,2),2,1)
    'end if    
end function


function GetCopyright
    GetCopyright = ""
end function     

Sub CloseWindow
    Response.Write("<SCRIPT LANGUAGE=javascript>"&Chr(13)&Chr(10))
    Response.Write("<!--"&Chr(13)&Chr(10))
    Response.Write("window.close();"&Chr(13)&Chr(10))
    Response.Write("//-->"&Chr(13)&Chr(10))
    Response.Write("</SCRIPT>"&Chr(13)&Chr(10))    
end Sub
                               
function GetClass(jyz,ml)
         
    if Int(ml) < 0 then
        GetClass = "恶人"
    else
        if jyz < 100 then 
            GetClass = "社区游民"
        end if
        if (jyz >=100) and (jyz < 500) then
            GetClass = "社区居民"
        end if
        if (jyz >= 500) and (jyz < 1000) then 
            GetClass = "合法公民"
        end if
        if (jyz >= 1000) and (jyz < 2000) then
            GetClass = "荣誉公民"
        end if
        if (jyz >= 2000) and (jyz < 3000) then
            GetClass = "高级社员"
        end if
        if (jyz >= 3000) and (jyz < 4000) then
            GetClass = "超级社员"
        end if
        if (jyz >= 4000) and (jyz < 5000) then
            GetClass = "荣誉社员"
        end if
		if (jyz >= 5000) and (jyz < 7000) then
            GetClass = "英 雄"
        end if
		if (jyz >= 7000) and (jyz < 10000) then
            GetClass = "精 英"
        end if
		if (jyz >= 10000) then
            GetClass = "通行者"
        end if 
    end if
end function 

function GetImage(jyz,ml)
    if Int(ml) < 0 then
        GetImage = 0
    else
        if jyz < 100 then 
            GetImage = 0
        end if
        if (jyz >=100) and (jyz < 500) then
            GetImage = 1
        end if
        if (jyz >= 500) and (jyz < 1000) then 
            GetImage = 1
        end if
        if (jyz >= 1000) and (jyz < 2000) then
            GetImage = 2
        end if
        if (jyz >= 2000) and (jyz < 3000) then
            GetImage = 3
        end if
        if (jyz >= 3000) and (jyz < 4000) then
            GetImage = 4
        end if
        if (jyz >= 4000) and (jyz < 5000) then
            GetImage = 4
        end if
		if (jyz >= 5000) and (jyz < 7000) then
            GetImage = 5
        end if   
        if (jyz >= 7000) and (jyz < 10000) then
            GetImage = 6
        end if
		if (jyz >= 10000) then
            GetImage = 7
        end if 
    end if
end function


function rd(min,max)
dim result
    Randomize
    result = Int((max-min+1)*Rnd+min)
    rd = result
end function

function GetFront(sSource,split)
	Dim iPos
	
	iPos = instr(sSource,split)
	if iPos > 0 then 
	    GetFront = mid(sSource, 1, iPos - 1)
	else 
	    GetFront = ""
	end if    
end function

function GetBack(sSource,split)
	Dim iPos

	iPos = instr(sSource,split)
	if iPos > 0 then 
	    GetBack = mid(sSource, iPos + len(split), len(sSource))
	else 
	    GetBack = ""
	end if    
end function

function GetPartEx(sSource,split,byPart)
    Dim byCount
    Dim Source

    Source = sSource&split
	if byPart > 0 then
  	    for byCount = 2 to byPart 
	        Source = GetBack(Source,split)
	    next    
	    GetPartEx = GetFront(Source,split)
	else 
	    GetPartEx = ""
	end if    
end function


function GetPart(sSource,byPart)
    GetPart = GetPartEx(sSource,"|",byPart)
end function


function ConvertDateTime(sj)
    if isDate(sj)  then
         ConvertDateTime = Year(sj)&"-"&IIF(Int(Month(sj)) < 10,"0"&Month(sj),Month(sj))&"-"&IIF(Int(Day(sj)) < 10,"0"&Day(sj),Day(sj))&" "&IIF(Int(Hour(sj)) < 10,"0"&Hour(sj),Hour(sj))&":"&IIF(Int(Minute(sj)) < 10,"0"&Minute(sj),Minute(sj))&":"&IIF(Int(Second(sj)) < 10,"0"&Second(sj),Second(sj))
    else
        ConvertDateTime = ""
    end if        
end function   
 


function IsObjInstalled(strClassString)
    On Error Resume Next
    IsObjInstalled = False
    Err = 0
    Dim xTestObj
    Set xTestObj = Server.CreateObject(strClassString)
    If Err = 0 Then 
        IsObjInstalled = True
    end if
    Set xTestObj = Nothing
    Err = 0
end function


function FilterStr(str)
   str = replace(str,"&","&#38",1)
   str = replace(str,"<","&lt;",1)
   str = replace(str,">","&gt;",1)
   str = replace(str,"|","|",1)
   str = replace(str,"\","/",1)
   str = replace(str,CHR(39),"&#39;",1)
   str = replace(str,Chr(34),"&quot;",1)
   str = replace(str,Chr(32),"&nbsp;",1)
   str = Replace(str, CHR(13), "",1)
   str = Replace(str, CHR(10) & CHR(10), "<P></P>",1)
   str = Replace(str, CHR(10), "<BR>",1)
   FilterStr = str
end function   

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -