<٪
FunctionHtmlencode (ByvalStrvalue)
'忽略错误
onerrorresumenext
'定义变量
Dimstrnewvalue
ifstrvalue <> "" ثم
strnewvalue = استبدال (strvalue ، "<" ، "<")
strnewvalue = استبدال (strnewvalue ، ">" ، ">")
strnewvalue = استبدال (strnewvalue ، "" "،" "")
strnewvalue = استبدال (strnewvalue ، "" "،" ")
strnewvalue = استبدال (strnewvalue ، vbcrlf ، "<br>")
strnewvalue = استبدال (strnewvalue ، "" ، "")
Endif
htmlencode = strnewvalue
'输出错误
iferr.number> 0then
استجابة. writeerr.description
استجابة
Endif
الوظيفية
POSTRICTUBBCODE (strvalue)
dimregexp
'strvalue = htmlencode (strvalue)
setRegexp = NewRegexp
regexp.ignorecase = صحيح
regexp.global = صحيح
ifstrvalue <> "" ثم
regexp.pattern = "(/[img //201 )(
strvalue = regexp.replace (strvalue ، "<ahref =" "$ 2" "target = _blank> <imgsrc =" $ 2 "" border = 0alt = 按此在新窗口浏览图片 onload = "" "javaScript: if (this.width> screen.width-333) this.width =
regexp.pattern = "(/[flash //201 )(
strvalue = regexp.replace (strvalue ، "<ObjectCodeBase =" "http://download.macromedia.com/pub/sho ... H/Swflash.cab#الإصدار = 4،0،2،0 "" classid = clsid: D27CDB6E-AE6D-11CF-96B8-444553540000WIDTH = 500HIGHT = 400ID = shockw aveflash1> <ParamName = filmValue = "" $ 2 ""> <ParamName = QualityValue = HIGH> <SIMPEDSRC = "" $ 2 "" Quality = HighpluginsPage = "" ") '' target = _blank rel = nofollow> http://www.macromedia.com/shockwave/download/index.cgi؟p1_prod_version=shockwaveflash" "type =" "appl ... 00height = 400> </inbed> </object>")
regexp.pattern = "(/[zip //201 )(
strvalue = regexp.replace (strvalue ، "<br> <herf =" "$ 2" "> 点击下载该文件 </a>")
regexp.pattern = "(/[rar //201 )(
strvalue = regexp.replace (strvalue ، "<br> <herf =" "$ 2" "> 点击下载该文件 </a>")
'regexp.pattern = "(/[upload = (. [^/[]*)/]) (.
'strvalue = regexp.replace (strvalue ، "<br> <br> <imgsrc =" "$ 2.gif" "border = 0> <hhref =" "$ 3" "target = _blank> 点击查看或下载该文件 </a>")
"strvalue = regexp.replace (strvalue ،" <br> <br> <imgsrc = "" $ 2.gif "" border = 0> 此主题相关图片如下 : <br> <hhref = "" $ 3 "" target = _blank> <IMGSRC = "" $ 3 "" border = 0alt = 按此在新窗口浏览图片 onload = "" javaScript: if (this.width> screen.width-333) this.width = screen.width-333 ""> </a>)