ks_cls/kesion.label.commoncls.asp
在最后
Function FormatImglink(content,url,totalpage)
dim re:Set re=new RegExp
re.IgnoreCase =true
re.Global=True
'去除onclick,onload等脚本
're.Pattern = "\s[on].+?=([\""|\'])(.*?)\1"
'Content = re.Replace(Content, "")
Dim LinkStr
If TotalPage=1 Then
LinkStr="href=""$2"" target=""_blank"""
Else
LinkStr="href=""" & Url & """"
End If
'将SRC不带引号的图片地址加上引号
re.Pattern = "<img.*?\ssrc=([^\""\'\s][^\""\'\s>]*).*?>"
Content = re.Replace(Content, "<a " & LinkStr & "><img src=""$2"" alt=""点击浏览下一页"" onmousewheel=""return bbimg(this)"" onload=""javascript:resizepic(this)"" border=""0""/></a>")
'正则匹配图片SRC地址
re.Pattern = "<img.*?\ssrc=([\""\'])([^\""\']+?)\1.*?>"
Content = re.Replace(Content, "<a " & LinkStr & "><img src=""$2"" alt=""点击浏览下一页"" onmousewheel=""return bbimg(this)"" onload=""javascript:resizepic(this)"" border=""0""/></a>")
set re = nothing
FormatImglink = content
end function
改成
Function FormatImglink(content,url,totalpage)
FormatImglink = content
end function