function addcontent(str1,str2){
form.nr.focus();
if ((document.selection)&&(document.selection.type== "Text")){
var range= document.selection.createRange();
var ch_text=range.text;
range.text= str1 + ch_text + str2;} 
else{
document.form.nr.value=document.form.nr.value+str1+str2;
form.nr.focus();}}

function shuziren_Color(){
var arr = showModalDialog("/edit/ubb/image/color.htm", "", "dialogWidth:18.5em; dialogHeight:17.5em; status:0; help:0");
if (arr != null){
form.nr.focus();
if ((document.selection)&&(document.selection.type== "Text")){
var range= document.selection.createRange();
var ch_text=range.text;
fontbegin="[color="+arr+"]";
fontend="[/color]";
range.text= fontbegin + ch_text + fontend;} 
else{
document.form.nr.value=document.form.nr.value+"[color="+arr+"]"+"[/color]";
form.nr.focus();
}}}

