这种突出强调了基于EditPlus

复制代码代码如下所示:
类wyd_aspcodehighlight
私人的正则表达式
公共关键字,objectcommand、弦、VBCode
公共keywordcolor,objectcommandcolor,stringscolor,评论,CodeColor
私有子class_initialize()
设置新的正则表达式正则表达式=
regex.ignorecase =真设置是否区分字母大小真的没有区别。
正则表达式。全球=真集完整性。
keywordcolor =# 0000ff
objectcommandcolor =# FF0000
stringscolor =# ff00ff
评论=# 008000
codecolor =# 993300
关键词=集|私人|如果|然后|子|端|功能|为|下|做|而|走|真|假|什么|类请把你自己的话。
objectcommand =左|中|右| int | CINT | CLNG |字符串|加入|阵列功能请自己添加
vbcode =
端子
私有子class_terminate()
设置正则表达式=没有
端子
私有函数m_replace(STR,图案,颜色)
正则表达式模式=模式的设置方式。
m_replace = regex.replace(STR,1美元)
端功能



私有函数string_replace(STR,模式,1型、颜色、isstring)
微弱的温度,RetStr
正则表达式模式= 1型。
设置匹配正则表达式执行(STR)=。
对每场比赛中的比赛的遍历匹配集
温度(匹配值)
STR =取代(STR,match.value,温度)
下一个
正则表达式模式=模式的设置方式。
如果isstring = 1
string_replace = regex.replace(STR,1美元)
其他的
string_replace = regex.replace(STR,1美元)
最后如果
端功能


私有函数(STR)
昏暗的tregex,温度
集tregex = new RegExp
tregex.ignorecase =真设置为区分案例与信。
tregex。全球=真集完整性。
tregex模式= 。
温度= tregex.replace(STR,)
温度=替换(温度, < <
温度=替换(温度,)>
Re =温度
集tregex =没有
端功能

公共函数MakeLi()
微弱的温度
如果VBCode = 然后
市长=
退出功能
最后如果
vbcode = HtmlEncode(vbcode)
温度= m_replace(vbcode, B(关键词) B,keywordcolor)
温度= m_replace(温度, B(objectcommand) B,objectcommandcolor)
温度= string_replace(温(。*
温度= string_replace(临时((| REM)2)
市长= repvbcrlf(临时)
端功能
公共功能repvbcrlf(fstring)
repvbcrlf =取代(fstring,CHR(10),)
端功能
公共函数的HTMLEncode(fstring)
如果IsNull(fstring)或fstring = 然后
HtmlEncode =
退出功能
最后如果
fstring =取代(fstring,> >,>)
fstring =取代(fstring,<
fstring =取代(fstring,CHR(32),)
fstring =取代(fstring,CHR(9),)
fstring =取代(fstring,CHR(34),)
fstring =取代(fstring,CHR(39),)
fstring =取代(fstring,CHR(13),)
fstring =取代(fstring,CHR(10)CHR(10),)
fstring =取代(fstring,CHR(10),)
HtmlEncode = fstring
端功能
类的结束




例子

复制代码代码如下所示:
星=定时器()
设置新的wyd_aspcodehighlight TT =
如果请求(),则
TT。vbcode =请求(XX)
Response.write TT.MakeLi()
response.write formatnumber(定时器()星级,2)* 1000
其他的

%>

类立
私人的正则表达式
公共关键字,objectcommand、弦、VBCode
公共keywordcolor,objectcommandcolor,stringscolor,评论
私有子class_initialize()
设置新的正则表达式正则表达式=
keywordcolor =# 0000ff
objectcommandcolor =# FF0000
stringscolor =# ff00ff
评论=# 008000
关键词=如果|端|为|下|功能|然后|做|而|走|类
vbcode =
端子
私有子class_terminate()
设置正则表达式=没有
端子
私有函数m_replace(STR,图案,颜色)
regex.ignorecase =假设置为区分案例与信。
正则表达式。全球=真集完整性。
正则表达式模式=模式的设置方式。