发现问题了
- function csf() {
- if (helpmode) {
- alert(daxiao_help);
- } else if (getSelectedText()) {
- var range = document.selection.createRange();
- text2=prompt(csf_tips,csf_normal_input2);
- range.text = "[csf="+range.text+"]"+text2+"[/csf]";
- } else if (advmode) {
- AddTxt="[csf="+csf_normal_input1+"]"+csf_normal_input3+"[/csf]\r";
- AddText(AddTxt);
- } else {
- txt2=prompt(csf_normal_input2,csf_normal_input3);
- if (txt2!=null) {
- txt=prompt(csf_normal_input1,csf_normal_input1);
- if (txt!=null) {
- if (txt2=="") {
- txt2=prompt(csf_normal_input2,csf_normal_input3);
- txt1=prompt(csf_normal_input1,csf_normal_input1);
- AddTxt="[csf="+txt1+"]"+txt2;
- AddText(AddTxt);
- AddText("[/csf]\r");
- } else {
- AddTxt="[csf="+txt+"]"+txt2;
- AddText(AddTxt);
- AddText("[/csf]\r");
- }
- }
- }
- }
- }
复制代码
该改成
- function csf() {
- if (helpmode) {
- alert(daxiao_help);
- } else if (getSelectedText()) {
- var range = document.selection.createRange();
- text2=prompt(csf_normal_help,csf_normal_input1);
- range.text = "[csf="+range.text+"]"+text1+"[/csf]";
- } else if (advmode) {
- AddTxt="[csf="+csf_normal_input3+"]"+csf_normal_input1+"[/csf]\r";
- AddText(AddTxt);
- } else {
- txt2=prompt(csf_normal_input1,csf_normal_input1);
- if (txt2!=null) {
- txt=prompt(csf_normal_input2,csf_normal_input3);
- if (txt!=null) {
- if (txt2=="") {
- txt2=prompt(csf_normal_input1,csf_normal_input1);
- txt1=prompt(csf_normal_input2,csf_normal_input3);
- AddTxt="[csf="+txt1+"]"+txt2;
- AddText(AddTxt);
- AddText("[/csf]\r");
- } else {
- AddTxt="[csf="+txt+"]"+txt2;
- AddText(AddTxt);
- AddText("[/csf]\r");
- }
- }
- }
- }
- }
复制代码
不然的话颜色会变黑色而只显示颜色的代码
[ 本帖最后由 ic3 于 2006-4-8 03:09 编辑 ] |