www.gusucode.com > CC校友录贴吧 CCBar源码程序asp编程 > inc/inc_ubb.asp

    <%
Dim GBL_strUbbFont,GBL_strUbbSize,GBL_strUbbColor,GBL_strUbbFont2,GBL_strUbbCenter,GBL_strUbbUrl,GBL_strUbbEmail,GBL_strUbbImg,GBL_strUbbFlash,GBL_strUbbQuote,GBL_strUbbFly,GBL_strUbbMove,strUbbGlow,GBL_strUbbShadown,h_html

'取得变量
h_html=0'rsconn1("h_html")'显示html

'过虑词语
function ChkBadWords(fString)
fString=replace(fString,"'","''")
    bwords = split(BadWords, "|")
    for i = 0 to ubound(bwords)
     fString = Replace(fString, bwords(i), string(len(bwords(i)),"*")) 
    next    
    ChkBadWords = fString
end function

'---------------- 过滤表单字符--------------------
function cpbhtmlencode(fString)

    fString = replace(fString, ">", "&gt;")
    fString = replace(fString, "<", "&lt;")
    fString = Replace(fString, CHR(32) & CHR(32), " &nbsp;")
    fString = Replace(fString, CHR(9), "&nbsp; &nbsp; &nbsp;")
   fString = Replace(fString, CHR(34), "&quot;")
    fString = Replace(fString, CHR(39), "&#39;")
    fString = Replace(fString, CHR(13), " ")
    fString = Replace(fString, CHR(10) & CHR(10), "</P><P>")
    fString = Replace(fString, CHR(10), "<BR>")
	 'fString = Replace(fString, CHR(10), "<br>")
    'fString=ChkBadWords(fString)
    cpbhtmlencode = fString
end function


function UBBCode(strContent)
    'strContent = cpbhtmlencode(strContent)

    dim re
    Set re=new RegExp' 建立正则表达式
    re.IgnoreCase =true'忽略大小写
    re.Global=True' 设置全局可用

re.Pattern="(javascript)"
strContent=re.Replace(strContent,"&#106avascript")
re.Pattern="(jscript:)"
strContent=re.Replace(strContent,"&#106script:")
re.Pattern="(js:)"
strContent=re.Replace(strContent,"&#106s:")
re.Pattern="(value)"
strContent=re.Replace(strContent,"&#118alue")
re.Pattern="(about:)"
strContent=re.Replace(strContent,"about&#58")
re.Pattern="(file:)"
strContent=re.Replace(strContent,"file&#58")
re.Pattern="(document.cookie)"
strContent=re.Replace(strContent,"documents&#46cookie")
re.Pattern="(vbscript:)"
strContent=re.Replace(strContent,"&#118bscript:")
re.Pattern="(vbs:)"
strContent=re.Replace(strContent,"&#118bs:")
re.Pattern="(on(mouse|exit|error|click|key))"
strContent=re.Replace(strContent,"&#111n$2")

'加入巧嘴娃娃 04/07/31
dim audibles_list,myrnd
Dim LoopN
Audibles_List = "|||就这事啊!地球人都知道|||嘿嘿!逗你玩!|||年轻人,做人要厚道!|||这干嘛?这不是那我打岔吗?|||一定要幸福喔!|||你好可爱耶!|||加油喔!|||我好想你喔 ~|||你不要这样嘛|||真的好感激你啊|||你简直太让我感动了!|||过来..近点...再近点...Kiss!|||强!实在是强!|||真真的么?我要晕了!|||最近真的好想你哦!|||啊你是中邪喔..|||你好讨厌喔~|||抽根烟吧!|||不干不干就是不干!|||饿不饿我请你吃饭|||听见了吗那是我肚子在叫|||哼!小样!我看你还真是找扁!|||坦白从宽,你就交代了吧!|||哼!你这骗子|||我就是喜欢你动作非常慢的时候...|||Hi!是你吧,我知道你在,我可看见你了!|||哎~~看来你真的很寂寞!|||年轻人虚心点没错|||这么说你还不明白,你猪头啊!|||掰掰啰!|||拜拜了您那|||哎呦!老板来了,我先走了啊!|||不行不行!我得上厕所...得上厕所!|||晚安做个好梦!|||我困得不行了得先走一步了|||有人在家吗?|||开会啰!|||早安!|||还在加班?真忙假忙啊?|||你可算来了,我等你很久了!|||来啦小妞|||早上好,您来啦!|||你要死啦~到现在才出现,到哪里潜水去啦...|||喂..我老板来了,先闪一下喽~下次再聊..|||啊~~~这是一定要的啦!|||嗯哼~人家.. 去撇个尿啰..嗯哼~|||嗯哼~来,亲一个~|||起来动一动吧,follow me! one more, two more…|||祝你生日快乐~祝你生日快乐..喔喔!祝你生日快乐喽|||不知道该说什么 ..|||好想睡喔...zzz|||让我想一想~~"
Audibles_List=split(Audibles_List,"|||")
           For LoopN = 1 to 52
Randomize Timer
MyRnd = Int(Rnd * 999999)&int(timer)
                           strContent=replace(strContent,"[AUDIO" & Right(("0" & LoopN),2) & "]","<P><table border=0 cellspacing=0 cellpadding=0><tr><td><OBJECT codeBase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=4,0,2,0' classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' width='48' height='48' Id='Audible"&myrnd&"'><PARAM NAME=movie VALUE='../plug-ins/audio/swf/"&Right("0" & LoopN,2)&".swf'><param name=menu value=false><PARAM NAME=quality VALUE=high><PARAM NAME=play VALUE=false><param name='wmode' value='transparent'><embed src='../plug-ins/audio/swf/"&Right("0" & LoopN,2)&".swf' quality='high' pluginspage='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash' type='application/x-shockwave-flash' width='48' height='48'></embed></OBJECT></td><td align='left' style='cursor:hand;'   onMouseOver='this.parentElement.children[0].children[0].Play()'>"&Audibles_List(loopN)&"</td></tr></table></p>",1,52,0)
                           strContent=replace(strContent,"[audio" & Right(("0" & LoopN),2) & "]","<P><table border=0 cellspacing=0 cellpadding=0><tr><td><OBJECT codeBase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=4,0,2,0' classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' width='48' height='48' Id='Audible"&myrnd&"'><PARAM NAME=movie VALUE='../plug-ins/audio/swf/"&Right("0" & LoopN,2)&".swf'><param name=menu value=false><PARAM NAME=quality VALUE=high><PARAM NAME=play VALUE=false><param name='wmode' value='transparent'><embed src='../plug-ins/audio/swf/"&Right("0" & LoopN,2)&".swf' quality='high' pluginspage='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash' type='application/x-shockwave-flash' width='48' height='48'></embed></OBJECT></td><td align='left' style='cursor:hand;'   onMouseOver='this.parentElement.children[0].children[0].Play()'>"&Audibles_List(loopN)&"</td></tr></table></p>",1,52,0)
               Next
'加入巧嘴娃娃结束

	dim checklockubbreply,checklockubb
       if  checklockubbreply=0 or checklockubb=0 then
    
	
	'== for board smileface
	re.Pattern="(\[BI\])(.[^\[]*)(\[\/BI\])"
    strContent = re.Replace(strContent,"<IMG SRC=""" & GBL_strHomeURL & GBL_strBoardFace & "$2" & ".gif" & """ border=0 align=middle> ")

	'== for smileface by cc
	re.Pattern="\[em(.[^\[]*)\]"
	strContent = re.Replace(strContent,"<img src=" & GBL_strHomeURL & "images/smile/$1.gif border=0 align=middle>")

	re.Pattern="(\[IMG\])(http|https|ftp):\/\/(.[^\[]*)(\[\/IMG\])"
	strContent=re.Replace(strContent,"<a onfocus=this.blur() href=""$2://$3"" target=_blank><IMG SRC=""$2://$3"" border=0 alt=按此在新窗口浏览图片 onLoad=""javascript:DrawImage2(this," & GBL_intImgWidth2 & ");""></a><br>")	
	
	re.Pattern="(\[uploadIMG\])(.[^\[]*)(\[\/uploadIMG\])"
	strContent=re.Replace(strContent,"<br><b>上传图片</b>:<br><a href=""upload/$2"" target=_blank><IMG SRC=""upload/$2"" border=0 alt=按此在新窗口浏览图片 onload=""javascript:if(this.width>screen.width-300)this.width=screen.width-300""><a>")
	
	re.Pattern="(\[uploadfile\])(.[^\[]*)(\[\/uploadfile\])"
	strContent=re.Replace(strContent,"<br><b>上传文件</b>:<br><a href=""upload/$2"" target=_blank title=按此浏览上传文件>按此浏览<a><br>")


	re.Pattern="(\[sound\])(.[^\[]*)(\[\/sound\])"
	strContent=re.Replace(strContent,"<br><b>加有背景音乐:</b><br><a href=""$2"" target=_blank title=按此收听>按此收听<a><br><bgsound src=""$2"">")
	
	 re.Pattern="(\[download\])(.[^\[]*)(\[\/download\])"
	strContent=re.Replace(strContent,"<IMG src=images/download.gif border=0><a href=""$2"" target=_blank title=点击下载><b>CPB--点击下载</b></a><BR>")
   
    re.Pattern="(\[frame\])(.[^\[]*)(\[\/frame\])"
	strContent=re.Replace(strContent,"<br><table align=center border=0 width=90% cellspacing=1 cellpadding=0 class=tdc><tr><td><iframe marginwidth=0 framespacing=0 marginheight=0 frameborder=2 width=100% height=200 src=""$2""></iframe></td></tr><tr><td><a href=""$2"" target=_blank>点这里访问</a></td></tr></table>")
	
	
    re.Pattern="\[DIR=*([0-9]*),*([0-9]*)\](http|https|ftp|mms):\/\/(.[^\[]*)\[\/DIR]"
	strContent=re.Replace(strContent,"<BR><b>影视文件:</b><a href=$3://$4>$3://$4</a><BR><object classid=clsid:166B1BCA-3F9C-11CF-8075-444553540000 codebase=http://download.macromedia.com/pub/shockwave/cabs/director/sw.cab#version=7,0,2,0 width=$1 height=$2><param name=src value=$3://$4><embed src=""$3://$4"" pluginspage=http://www.macromedia.com/shockwave/download/ width=$1 height=$2></embed></object><BR>")
	
	re.Pattern="(\[cc])(.[^\[]*)(\[\/cc])"
	strContent=re.Replace(strContent,"<object classid=""clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"" codebase=""http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0"" width=""438"" height=""387""><param name=""movie"" value=""http://union.bokecc.com/$2""><param name=""allowFullScreen"" value=""true"" /> <param name=""quality"" value=""high""><embed src=""http://union.bokecc.com/$2"" quality=""high"" pluginspage=""http://www.macromedia.com/go/getflashplayer"" type=""application/x-shockwave-flash"" width=""438"" height=""387"" allowFullscreen=""true"" ></embed></object>")
	
	re.Pattern="\[QT=*([0-9]*),*([0-9]*)\](http|https|rtsp|ftp|mms):\/\/(.[^\[]*)\[\/QT]"
	strContent=re.Replace(strContent,"<BR><b>影视文件:</b><a href=$3://$4>$3://$4</a><BR><embed src=$3://$4 width=$1 height=$2 autoplay=false loop=false controller=true playeveryframe=false cache=false scale=TOFIT bgcolor=#000000 kioskmode=false targetcache=false pluginspage=http://www.apple.com/quicktime/><BR>")
	
	re.Pattern="\[MP=*([0-9]*),*([0-9]*)\](http|rtsp|https|ftp|mms):\/\/(.[^\[]*)\[\/MP]"
	strContent=re.Replace(strContent,"<BR><b>影视文件:</b><a href=$3://$4>$3://$4</a><BR><object align=middle classid=CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95 class=OBJECT id=MediaPlayer width=$1 height=$2 ><param name=ShowStatusBar value=-1><param name=Filename value=$3://$4><embed type=application/x-oleobject codebase=http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701 flename=mp src=$3://$4  width=$1 height=$2></embed></object><BR>")
	
	re.Pattern="\[RM=*([0-9]*),*([0-9]*)\](http|https|rtsp|ftp|mms):\/\/(.[^\[]*)\[\/RM]"
	strContent=re.Replace(strContent,"<BR><b>影视文件:</b><a href=$3://$4>$3://$4</a><BR><OBJECT classid=clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA class=OBJECT id=RAOCX width=$1 height=$2><PARAM NAME=SRC VALUE=$3://$4><PARAM NAME=CONSOLE VALUE=Clip1><PARAM NAME=CONTROLS VALUE=imagewindow><PARAM NAME=AUTOSTART VALUE=false></OBJECT><br><OBJECT classid=CLSID:CFCDAA03-8BE4-11CF-B84B-0020AFBBCCFA height=32 id=video2 width=$1><PARAM NAME=SRC VALUE=$3://$4><PARAM NAME=AUTOSTART VALUE=0><PARAM NAME=CONTROLS VALUE=controlpanel><PARAM NAME=CONSOLE VALUE=Clip1></OBJECT><BR>")
    
    'flash转换
    re.Pattern="\[flash=*([0-9]*),*([0-9]*)\](http|https|ftp):\/\/(.[^\[]*)\[\/flash\]"
	strContent= re.Replace(strContent,"<BR><OBJECT codeBase=http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=4,0,2,0 classid=clsid:D27CDB6E-AE6D-11cf-96B8-444553540000 width=$1 height=$2><PARAM NAME=movie VALUE=""$3://$4""><PARAM NAME=quality VALUE=high><embed src=""$3://$4"" quality=high pluginspage='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash' type='application/x-shockwave-flash' width=$1 height=$2>$3://$4</embed></OBJECT><BR>")
    
    
	
    
  'url与email 转换
re.Pattern="(\[URL\])(.[^\[]*)(\[\/URL\])"
strContent= re.Replace(strContent,"<A HREF=""$2"" TARGET=_blank>$2</A>")
re.Pattern="(\[URL=(.[^\[]*)\])(.[^\[]*)(\[\/URL\])"
strContent= re.Replace(strContent,"<A HREF=""$2"" TARGET=_blank>$3</A>")

re.Pattern="(\[\/LIGHT\])"
strContent=re.Replace(strContent,"[/LIGHT]" & VbCrLf)
re.Pattern="\[LIGHT\](.*)\[\/LIGHT]"
strContent=re.Replace(strContent,"<span style=""behavior:url(" & GBL_strHomeURL & "inc/font.htc)"">$1</span>")
strContent = Replace(strContent,VbCrLf,"")


re.Pattern="(\[EMAIL\])((\w)+[@]{1}(\w)+[.]{1,3}(\w)+)(\[\/EMAIL\])"
strContent= re.Replace(strContent,"<img align=absmiddle src=" & GBL_strHomeURL & "images/ubb/email.gif><A HREF=""mailto:$2"">$2</A>")
re.Pattern="(\[EMAIL=((\w)+[@]{1}(\w)+[.]{1,3}(\w)+)\])(.[^\[]*)(\[\/EMAIL\])"
strContent= re.Replace(strContent,"<img align=absmiddle src=images/email.gif><A HREF=""mailto:$2"" TARGET=_blank>$3</A>")

'自动寻找
'if checkurl="1" or checkurlreply="1" then

'自动识别网址
re.Pattern = "([^>=""])((http|https|ftp|rtsp|mms):(\/\/|\\\\)[A-Za-z0-9\./=\?%\-&_~`@':+!]+)"
strContent = re.Replace(strContent,"$1<img align=absmiddle src=" & GBL_strHomeURL & "images/ubb/url.gif border=0><a target=_blank href=$2>$2</a>")
'自动识别www开头的网址
re.Pattern = "([^(http://|http:\\)])((www|cn)[.](\w)+[.]{1,}(net|com|cn|org|cc)(((\/[\~]*|\\[\~]*)(\w)+)|[.](\w)+)*(((([?](\w)+){1}[=]*))*((\w)+){1}([\&](\w)+[\=](\w)+)*)*)$" 
strContent = re.Replace(strContent,"<img align=absmiddle src=images/url.gif border=0><a target=_blank href=""$2"">$2</a>")

'自动识别Email地址
're.Pattern ="([^(=)])((\w)+[@]{1}((\w)+[.]){1,3}(\w)+)"
'strContent = re.Replace(strContent,"<img align=absmiddle src=images/email.gif border=0><a target=_blank href=""mailto:$2"">$2</a>")	
	'end if
	'代码转换
    re.Pattern="\[code\](.[^\[]*)\[\/code\]"
	dim bgcolor,bgcolor1,rcount,Matches,Match
	strContent=re.Replace(strContent,"<table width='100%' border='0' cellspacing='0' cellpadding='6' bgcolor='"&bgcolor1&"' class=tdc><td><b>以下为程序代码:</b><br>$1</td></table>")
	
	'代码转换
    re.Pattern="\[html\](.[^\[]*)\[\/html\]"
	strContent=re.Replace(strContent,"<br><b>以下为html代码:<textarea id=fy"&rcount&" style=width:95% rows=10 class=bdtj3>$1</textarea><br><script src=open.js></script><INPUT onclick=runEx() type=button value=运行此段代码 name=Button1 class=bdtj3> <INPUT onclick=JM_cc('fy"&rcount&"') type=button value=复制到我的剪贴板 name=Button2 class=bdtj3></B><Br>如果看不到效果或效果有问题,请将代码保存为html文件查看.<br>")

	'引用
   re.Pattern="(\[\/QUOTE\])"
		strContent=re.Replace(strContent,"[/QUOTE]" & VbCrLf)
		re.Pattern="\[QUOTE\](.*)\[\/QUOTE]"
		strContent=re.Replace(strContent,"<table width=100% bgcolor=" & DEF_WEB_DarkColor & " cellpadding=5 cellspacing=1 class=forum_list_table><tr><td bgcolor=" & DEF_WEB_LightestColor & " class=forum_list_tr><font color=#999999>$1</font></td></tr></table>")
		strContent = Replace(strContent,VbCrLf,"")

    Set Matches=re.Execute(strContent)
    '加多这个循环为的是ubb可以套用
        for each Match in matches
    strcontent = re.Replace(strContent, replStr) 
    strcontent = re.Replace(strcontent, replStr)
    next 

    '一般的文字处理
   re.Pattern="\[color=(.[^\[]*)\](.[^\[]*)\[\/color\]"
   strContent=re.Replace(strContent,"<font color=$1>$2</font>")
	
	re.Pattern="\[face=(.[^\[]*)\](.[^\[]*)\[\/face\]"
	strContent=re.Replace(strContent,"<font face=$1>$2</font>")
	
	re.Pattern="\[align=(center|left|right)\](.[^\[]*)\[\/align\]"
	strContent=re.Replace(strContent,"<div align=$1>$2</div>")
	
   re.Pattern="\[fly\](.[^\[]*)\[\/fly\]"
 	strContent=re.Replace(strContent,"<marquee width=90% behavior=alternate scrollamount=3>$1</marquee>")
	
	re.Pattern="\[move\](.[^\[]*)\[\/move\]"
	strContent=re.Replace(strContent,"<MARQUEE scrollamount=3>$1</marquee>")
	
	re.Pattern="\[GLOW=*([0-9]*),*((\w)+),*([0-9]*)\](.[^\[]*)\[\/GLOW]"
	strContent=re.Replace(strContent,"<table width=$1 style=""filter:glow(color=$2, strength=$4)"">$5</table>")
	
	re.Pattern="\[SHADOW=*([0-9]*),*((\w)+),*([0-9]*)\](.[^\[]*)\[\/SHADOW]"
	strContent=re.Replace(strContent,"<table width=$1 style=""filter:shadow(color=$2, strength=$4)"">$5</table>")
	
	 re.Pattern="\[i\](.[^\[]*)\[\/i\]"
	strContent=re.Replace(strContent,"<i>$1</i>")
	
	 re.Pattern="\[center\](.[^\[]*)\[\/center\]"
	strContent=re.Replace(strContent,"<center>$1</center>")
	
	re.Pattern="\[u\](.[^\[]*)(\[\/u\])"
	strContent=re.Replace(strContent,"<u>$1</u>")
	
	re.Pattern="\[b\](.[^\[]*)(\[\/b\])"
	strContent=re.Replace(strContent,"<b>$1</b>")    
re.Pattern="\[size=([1-6])\](.[^\[]*)\[\/size\]"
strContent=re.Replace(strContent,"<font size=$1>$2</font>")
	
	 strContent=replace(strContent,"[br]","<br>")
	 
end if
    set re=Nothing
    UBBCode=strContent
end function

'== Ubb ico show

GBL_strUbbFont = "<SELECT onchange='SelectFont()' name=font><option>字体</option><option value='宋体'>宋体</option><option value='楷体_GB2312'>楷体</option><option value='新宋体'>新宋</option> <option value='黑体'>黑体</option><option value='隶书'>隶书</option><option value='Arial'>Arial</option></SELECT> "

GBL_strUbbSize = "<select name='size' onChange='SelectSize()'><option>大小</option><option value='1'>1</option><option value='2'>2</option><option value='3'>3</option><option value='4'>4</option></select> "

GBL_strUbbColor = "<SELECT onchange='SelectColor()' name=color><option>颜色</option><option style='background-color:#00FFFF;color: #00FFFF' value='#00FFFF'>#00FFFF</option><option style='background-color:#6495ED;color: #6495ED' value='#6495ED'>#6495ED</option><option style='background-color:#0000FF;color: #0000FF' value='#0000FF'>#0000FF</option><option style='background-color:#00008B;color: #00008B' value='#00008B'>#00008B</option><option style='background-color:#FFA500;color: #FFA500' value='#FFA500'>#FFA500</option><option style='background-color:#FF6347;color: #FF6347' value='#FF6347'>#FF6347</option><option style='background-color:#FF0000;color: #FF0000' value='#FF0000'>#FF0000</option><option style='background-color:#B22222;color: #B22222' value='#B22222'>#B22222</option><option style='background-color:#008000;color: #008000' value='#008000'>#008000</option><option style='background-color:#00FF00;color: #00FF00' value='#00FF00'>#00FF00</option><option style='background-color:#20B2AA;color: #20B2AA' value='#20B2AA'>#20B2AA</option><option style='background-color:#FF00FF;color: #FF00FF' value='#FF00FF'>#FF00FF</option><option style='background-color:#CD5C5C;color: #CD5C5C' value='#CD5C5C'>#CD5C5C</option><option style='background-color:#8B008B;color: #8B008B' value='#8B008B'>#8B008B</option><option style='background-color:#4B0082;color: #4B0082' value='#4B0082'>#4B0082</option><option style='background-color:#FFE4C4;color: #FFE4C4' value='#FFE4C4'>#FFE4C4</option><option style='background-color:#F4A460;color: #F4A460' value='#F4A460'>#F4A460</option><option style='background-color:#DAA520;color: #DAA520' value='#DAA520'>#DAA520</option><option style='background-color:#CD853F;color: #CD853F' value='#CD853F'>#CD853F</option><option style='background-color:#8FBC8F;color: #8FBC8F' value='#8FBC8F'>#8FBC8F</option><option style='background-color:#A9A9A9;color: #A9A9A9' value='#A9A9A9'>#A9A9A9</option></SELECT> "

GBL_strUbbFont2 = "<img onClick=Cbold() src='" & GBL_strHomeURL & "images/ubb/" & "bold.gif' width=19  height=19  alt='粗体' border='0' style='CURSOR:hand'> <img onclick=Citalic() src='" & GBL_strHomeURL & "images/ubb/" & "code.gif' width=19  height=19  alt='斜体' border='0' style='CURSOR:hand'> <img onclick=Cunder() src='" & GBL_strHomeURL & "images/ubb/" & "underline.gif' width=19  height=19  alt='下划线' border='0' style='CURSOR:hand'> "

GBL_strUbbCenter = "<img onclick=Ccenter() src='" & GBL_strHomeURL & "images/ubb/" & "center.gif' width=19  height=19  alt='居中' border='0' style='CURSOR:hand'> "

GBL_strUbbUrl = "<img onclick=Curl() src='" & GBL_strHomeURL & "images/ubb/" & "url1.gif' width=19  height=19  alt='超级连接' border='0' style='CURSOR:hand'> "

GBL_strUbbEmail = "<img onclick=Cemail() src='" & GBL_strHomeURL & "images/ubb/" & "email1.gif' width=19  height=19  alt='Email连接' border='0' style='CURSOR:hand'> "

GBL_strUbbImg = "<img onclick=Cimage() src='" & GBL_strHomeURL & "images/ubb/" & "image.gif' width=19  height=19  alt='图片' border='0' style='CURSOR:hand'> "

GBL_strUbbFlash = "<img onclick=Cswf() src='" & GBL_strHomeURL & "images/ubb/" & "swf.gif' width=19  height=19  alt='Flash图片' border='0' style='CURSOR:hand'> "

Dim GBL_strUbbRm : GBL_strUbbRm = "<img onclick=Crm() src='" & GBL_strHomeURL & "images/ubb/" & "rm.gif' width=19  height=19  alt='影视播放' border='0' style='CURSOR:hand'> "

Dim GBL_strUbbSound : GBL_strUbbSound = "<img onclick=Csound() src='" & GBL_strHomeURL & "images/ubb/" & "rm.gif' width=19  height=19  alt='影视播放' border='0' style='CURSOR:hand'> "

GBL_strUbbQuote = "<img onclick=Cquote() src='" & GBL_strHomeURL & "images/ubb/" & "quote1.gif' width=19  height=19  alt='引用' border='0' style='CURSOR:hand'> "

GBL_strUbbFly = "<IMG onclick=Cfly() height=19  alt=飞行字 src='" & GBL_strHomeURL & "images/ubb/" & "fly.gif' width=19  border=0 style='CURSOR:hand'> "

GBL_strUbbMove = "<IMG onclick=Cmarquee() height=19 width=19  alt=移动字 src='" & GBL_strHomeURL & "images/ubb/" & "move.gif' width=19 height=19 border=0 style='CURSOR:hand'> "

strUbbGlow = "<IMG onclick=Cguang() height=19 width=19 alt=发光字 src='" & GBL_strHomeURL & "images/ubb/" & "glow.gif' width=19 height=19  border=0 style='CURSOR:hand'> "

GBL_strUbbShadown = "<IMG onclick=Cying() height=19  alt=阴影字 src='" & GBL_strHomeURL & "images/ubb/" & "shadow.gif' width=19  border=0 style='CURSOR:hand'> "

GBL_strUbbShadown = "<IMG onclick=Clight() height=19  alt=闪烁字 src='" & GBL_strHomeURL & "images/ubb/" & "light.gif' width=19  border=0 style='CURSOR:hand'> "

Dim GBL_strMop : GBL_strMop = "<a href=""javascript:openEditScript('../plug-ins/audio/show.htm',450,370);"" title=插入巧嘴娃娃><img src="""& GBL_strHomeURL &"/images/ubb/audio.gif"" width=19 height=19 align=absmiddle border=0></a>"

If Trim(Application(GBL_strCookieURL & "APP_strCCID")) <> ""  Then
	GBL_strMop = GBL_strMop & "&nbsp;<object width='86' height='22'><param name='wmode' value='transparent' /><param name='allowScriptAccess' value='always' /><param name='movie' value='http://union.bokecc.com/flash/plugin/plugin_16.swf?userID=" & Trim(Application(GBL_strCookieURL & "APP_strCCID")) & "&type=ccrelease' /><embed src='http://union.bokecc.com/flash/plugin/plugin_16.swf?userID=" & Trim(Application(GBL_strCookieURL & "APP_strCCID")) & "&type=ccrelease' type='application/x-shockwave-flash' width='86' height='22' allowScriptAccess='always' wmode='transparent' ></embed></object>"
End If

Function GetUbb()
%>
<script language=javascript> 
function openEditScript(url, width, height)
{
	var Win = window.open(url,"openEditScript",'width=' + width + ',height=' + height + ',resizable=1,scrollbars=yes,menubar=no,status=no' );
}
</script>
<%
GetUbb = ""
GetUbb = GBL_strUbbFont & GBL_strUbbSize & GBL_strUbbColor & GBL_strUbbFont2 & "<br>" & GBL_strUbbCenter & GBL_strUbbUrl & GBL_strUbbEmail & GBL_strUbbImg & GBL_strUbbFlash &  GBL_strUbbRm & GBL_strUbbQuote & GBL_strUbbFly & GBL_strUbbMove & strUbbGlow & GBL_strUbbShadown & GBL_strMop

End Function

'===================================================================
'= Function     : ShowSmileList(strName,intStart,intEnd,intStep)
'= Time		    : Created At Feb,13,2004
'= Input        : 
'= Output       : 
'= Called by    : 
'= Calls        : 
'= Description  : show smile of txtcontent
'===================================================================
Function ShowSmileList(strName,intStart,intEnd,intStep)

	Dim strOutTmp
	Dim strTmp
	Dim i,k
	
	k = 0
	strOutTmp = "<table cellpadding=0 cellspacing=0  id='" & strName & "' style='DISPLAY: none'><tr><td>" & vbCrLf
	strOutTmp = strOutTmp & vbCrLf
	
	For i = intStart To intEnd
		k = k + 1
		strOutTmp = strOutTmp & "<img src='" & GBL_strHomeURL & "images/smile/" & i & ".gif' alt='插入表情' style='CURSOR:hand' onclick=""addcontent('[em" & i & "]','');""> "
		If k Mod intStep = 0 Then
			strOutTmp = strOutTmp & "<br>"
		End If
	Next

	strOutTmp = strOutTmp & "</td></tr></table>" & vbCrLf
	
	ShowSmileList = strOutTmp

End Function
'=============== End of func ShowSmileList() =======================
'===================================================================
'= Function     : ShowSmileOut(intStep)
'= Time		    : Created At Feb,13,2004
'= Input        : 
'= Output       : 
'= Called by    : 
'= Calls        : 
'= Description  : show smile of txtcontent
'===================================================================
Function ShowSmileOut(intStep)
	
	Dim strHtmlCode

	strHtmlCode = ""
	strHtmlCode = "<INPUT id=rdoSmile name=rdoSmile type=radio value=1 onclick=OutSmileList(this,s1,s2,s3,s4,s5) class=CSS_IPT_RADIO><span id=advance>表情1</span>"
	strHtmlCode = strHtmlCode & "<INPUT id=rdoSmile name=rdoSmile type=radio value=1 onclick=OutSmileList(this,s2,s1,s3,s4,s5) class=CSS_IPT_RADIO><span id=advance>表情2</span>"
	strHtmlCode = strHtmlCode & "<INPUT id=rdoSmile name=rdoSmile type=radio value=1 onclick=OutSmileList(this,s3,s1,s2,s4,s5) class=CSS_IPT_RADIO><span id=advance>表情3</span>"
	strHtmlCode = strHtmlCode & "<INPUT id=rdoSmile name=rdoSmile type=radio value=1 onclick=OutSmileList(this,s4,s1,s2,s3,s5) class=CSS_IPT_RADIO><span id=advance>表情4</span>"
	strHtmlCode = strHtmlCode & "<INPUT id=rdoSmile name=rdoSmile type=radio value=1 onclick=OutSmileList(this,s5,s1,s2,s3,s4) class=CSS_IPT_RADIO><span id=advance>包子1</span>"
	strHtmlCode = strHtmlCode & ShowSmileList("s1",1,22,intStep) & ShowSmileList("s2",23,44,intStep) & ShowSmileList("s3",45,66,intStep) & ShowSmileList("s4",67,100,intStep) & ShowSmileList("s5",155,169,intStep - 6) 

	ShowSmileOut = strHtmlCode
	strHtmlCode = ""

End Function
'=============== End of Func ShowSmileOut() ===============================
%>