The key code that is deleted in the directory!

xiaoxiao2021-03-06  59

// Add to related pages <% const saveupfilespath = "picture storage relative path" DIM STRFILENAMEDIM UPLOADDIR, Truepath, Fso, Thefolder, Thefile, Whichfile, thisfile , FileCount, TotlesizestrFileName = "File name this page .asp" if right (saveupfilespath, 1) <> "/" THEN UPLOADDIR = "../" & SaveupFilesPath & "/" Else UploadDir = "../" & SaveupFileSpathend ifTruePath = Server.MapPath (uploadDir) If not IsObjInstalled ( "Scripting.FileSystemObject") Then Response.Write " your server does not support FSO (Scripting.FileSystemObject)! you can not use this feature "Else Set fso = creteObject (" scripting.filesystemObject ") if Request (" action ") =" del "dam (Request (" FileName ") SET thisfile = fso.getfile (Whichfile) thisfile.delete truend IF%> Function.asp <% '**************************************************** *************** 'Function Name: Gottopic' Job: Cross-strings, Chinese characters, two characters, English calculation a character 'parameter: STR ---- original characters String 'Strlen ---- Intercept length' Return value: The string after interception '**************************************** ****************** FUNCTION GOTTOPIC (Str, Strl En) if str = "" Then gottopic = "" EXIT FUNCTION END IF DIM L, T, C, I STR = Replace (Replace (Replace (STR, "," "," "", "" ", CHR (34 )), ">", ">"), "<", "<") L = LEN (STR) T = 0 for i = 1 to l C = ABS (ASC (MID (STR, I, 1)) IF C> 255 THEN T = T 2 else t = t

1 End if IF T> = Strlen Ten Gottopic = Left (STR, I) & "..." EXIT for else gottopic = STR End if Next Gottopic = Replace (Replace (Replace (replace (replace (replace (replace (replace (gottopic, ",", "" (34), "" "", ">", ">"), "<", "<") end function '******************** ************************** Function name: joinchar 'Join: Add? Or &' parameters: Strurl --- - Website 'Return Value: Added? Or & Webster' ****************************************************** *********** Function JoinChar (Strurl) if strurl = "" "" "" ""? "" "?") 1 THEN IF INSTR (Strurl, "&")

转载请注明原文地址:https://www.9cbs.com/read-116934.html

New Post(0)