The code copy is as follows:
<%
'-------------------------------------
'Tianfeng ASPclassv1.0, integrates commonly used asp functions
'Tianfeng Copyright http://www.52515.net
'QQ:76994859EMAIL:[email protected]
'All function names are as follows:
'StrLength(str) gets the string length
'CutStr(str,strlen) string length cut
'CheckIsEmpty(tstr) checks whether it is empty
'isInteger(para) integer test
'CheckName(str)Name Character Verification
'CheckPassword(str) Password Verification
'CheckEmail(email) mailbox format verification
'Alert(msg,goUrl) pop-up dialog box prompt
'GoBack(Str1,Str2,isback) error message
'Suc(str1,str2,url) operation success information prompt
'ChkPost() detects whether to submit a form outside the site
'PSql() prevents sql injection
'FiltrateHtmlCode(Str) prevents HTML generation
'HtmlCode(str) filter HTML
'Replacehtml(tstr) Clear HTML
'GetIP() gets the client IP
'GetBrowser gets the client browser message
'GetSystem gets the client operating system
'GetUrl() gets the current page URL contains parameters
'CUrl() gets the current page URL
'GetExtend gets the file extension
'CheckExist(table,fieldname,fieldcontent,isblur) detects whether the content of a field in a certain table exists
'GetNum(table,fieldname,resulttype,args) detects how many fields there are in a certain table, maximum value, minimum value, etc.
'GetFolderSize(Folderpath) calculates the size of a certain folder
'GetFileSize(Filename) calculates the size of a file
'IsObjInstalled(strClassString) checks whether the component is installed
'SendMailJMAIL Send mail
'ResponseCookies Write cookies
'CleanCookies Clear cookies
'GetTimeover gets the execution time of the program page
'FormatSize size formatting
'FormatTime Time Format
'Zodiac obtains zodiac
'Constellation to obtain constellation
'-------------------------------------
ClassCls_fun
'-----------------------------------------�
'*********************************************************
'Function name: StrLength
'Function: Get the length of the string (Chinese characters are 2)
'Arguments: str-----string content
'Return value: string length
'*********************************************************
PublicfunctionStrLength(str)
DimRep,lens,i