defmode = "normalmode"; // default mode (normalmode, advmode, helpmode)
if (defmode == "advmode") {
helpmode = false;
normalmode = false;
advmode = true;
} else if (defmode == "helpmode") {
helpmode = true;
normalmode = false;
advmode = false;
} else {
helpmode = false;
normalmode = true;
advmode = false;
}
function chmode(swtch){
if (swtch == 1){
advmode = false;
normalmode = false;
helpmode = true;
alert(help_mode);
} else if (swtch == 0) {
helpmode = false;
normalmode = false;
advmode = true;
alert(adv_mode);
} else if (swtch == 2) {
helpmode = false;
advmode = false;
normalmode = true;
alert(normal_mode);
}
}
function AddText(NewCode) {
if(document.all){
insertAtCaret(document.form1.T_Content, NewCode);
setfocus();
} else{
document.form1.T_Content.value += NewCode;
setfocus();
}
}
function storeCaret (textEl){
if(textEl.createTextRange){
textEl.caretPos = document.selection.createRange().duplicate();
}
}
function insertAtCaret (textEl, text){
if (textEl.createTextRange && textEl.caretPos){
var caretPos = textEl.caretPos;
caretPos.text += caretPos.text.charAt(caretPos.text.length - 2) == ' ' ? text + ' ' : text;
} else if(textEl) {
textEl.value += text;
} else {
textEl.value = text;
}
}
function email() {
if (helpmode) {
alert(email_help);
} else if (document.selection && document.selection.type == "Text") {
var range = document.selection.createRange();
range.text = "[email]" + range.text + "[/email]";
} else if (advmode) {
AddTxt="[email] [/email]";
AddText(AddTxt);
} else {
txt2=prompt(email_normal,"");
if (txt2!=null) {
txt=prompt(email_normal_input,"name@domain.com");
if (txt!=null) {
if (txt2=="") {
AddTxt="[email]"+txt+"[/email]";
} else {
AddTxt="[email="+txt+"]"+txt2+"[/email]";
}
AddText(AddTxt);
}
}
}
}
function chsize(size) {
if (helpmode) {
alert(fontsize_help);
} else if (document.selection && document.selection.type == "Text") {
var range = document.selection.createRange();
range.text = "[size=" + size + "]" + range.text + "[/size]";
} else if (advmode) {
AddTxt="[size="+size+"] [/size]";
AddText(AddTxt);
} else {
txt=prompt(fontsize_normal,text_input);
if (txt!=null) {
AddTxt="[size="+size+"]"+txt;
AddText(AddTxt);
AddText("[/size]");
}
}
}
function chfont(font) {
if (helpmode){
alert(font_help);
} else if (document.selection && document.selection.type == "Text") {
var range = document.selection.createRange();
range.text = "[font=" + font + "]" + range.text + "[/font]";
} else if (advmode) {
AddTxt="[font="+font+"] [/font]";
AddText(AddTxt);
} else {
txt=prompt(font_normal,text_input);
if (txt!=null) {
AddTxt="[font="+font+"]"+txt;
AddText(AddTxt);
AddText("[/font]");
}
}
}
function bold() {
if (helpmode) {
alert(bold_help);
} else if (document.selection && document.selection.type == "Text") {
var range = document.selection.createRange();
range.text = "[b]" + range.text + "[/b]";
} else if (advmode) {
AddTxt="[b] [/b]";
AddText(AddTxt);
} else {
txt=prompt(bold_normal,text_input);
if (txt!=null) {
AddTxt="[b]"+txt;
AddText(AddTxt);
AddText("[/b]");
}
}
}
function italicize() {
if (helpmode) {
alert(italicize_help);
} else if (document.selection && document.selection.type == "Text") {
var range = document.selection.createRange();
range.text = "[i]" + range.text + "[/i]";
} else if (advmode) {
AddTxt="[i] [/i]";
AddText(AddTxt);
} else {
txt=prompt(italicize_normal,text_input);
if (txt!=null) {
AddTxt="[i]"+txt;
AddText(AddTxt);
AddText("[/i]");
}
}
}
function quote() {
if (helpmode){
alert(quote_help);
} else if (document.selection && document.selection.type == "Text") {
var range = document.selection.createRange();
range.text = "[quote]" + range.text + "[/quote]";
} else if (advmode) {
AddTxt="\r[quote]\r[/quote]";
AddText(AddTxt);
} else {
txt=prompt(quote_normal,text_input);
if(txt!=null) {
AddTxt="\r[quote]\r"+txt;
AddText(AddTxt);
AddText("\r[/quote]");
}
}
}
function chcolor(color) {
if (helpmode) {
alert(color_help);
} else if (document.selection && document.selection.type == "Text") {
var range = document.selection.createRange();
range.text = "[color=" + color + "]" + range.text + "[/color]";
} else if (advmode) {
AddTxt="[color="+color+"] [/color]";
AddText(AddTxt);
} else {
txt=prompt(color_normal,text_input);
if(txt!=null) {
AddTxt="[color="+color+"]"+txt;
AddText(AddTxt);
AddText("[/color]");
}
}
}
function center() {
if (helpmode) {
alert(center_help);
} else if (document.selection && document.selection.type == "Text") {
var range = document.selection.createRange();
range.text = "[align=center]" + range.text + "[/align]";
} else if (advmode) {
AddTxt="[align=center] [/align]";
AddText(AddTxt);
} else {
txt=prompt(center_normal,text_input);
if (txt!=null) {
AddTxt="\r[align=center]"+txt;
AddText(AddTxt);
AddText("[/align]");
}
}
}
function hyperlink() {
if (helpmode) {
alert(link_help);
} else if (advmode) {
AddTxt="[url] [/url]";
AddText(AddTxt);
} else {
txt2=prompt(link_normal,"");
if (txt2!=null) {
txt=prompt(link_normal_input,"http://");
if (txt!=null) {
if (txt2=="") {
没有合适的资源?快使用搜索试试~ 我知道了~
雨点单用户免费留言板
共86个文件
jpg:30个
gif:23个
asp:23个
需积分: 10 7 下载量 82 浏览量
2008-12-11
10:52:43
上传
评论
收藏 477KB RAR 举报
温馨提示
ASP免费留言板代码下载,单用户免费留言板,完全免费!最新代码!
资源推荐
资源详情
资源评论
收起资源包目录
.rar (86个子文件)
雨点单用户免费留言板
modify.asp 5KB
Inc_ubb.asp 5KB
mydata.mdb 172KB
delete_message.asp 289B
top.asp 3KB
inc
ubbcode.js 14KB
ubbhelp.js 3KB
modify.js 989B
myjs.js 1KB
md5.asp 11KB
reply_save.asp 375B
cookies.asp 134B
image
a8.jpg 7KB
call.gif 453B
bg.gif 530B
repost.gif 450B
a11.jpg 8KB
email.gif 452B
a6.jpg 7KB
del.gif 512B
a15.jpg 7KB
b12.jpg 7KB
b4.jpg 7KB
b13.jpg 6KB
add.gif 422B
re.gif 263B
check.gif 83B
b8.jpg 6KB
home.gif 441B
a1.jpg 8KB
a7.jpg 8KB
b11.jpg 8KB
body.Fix 3KB
a9.jpg 7KB
a14.jpg 7KB
b3.jpg 8KB
b5.jpg 7KB
Thumbs.db 262KB
b9.jpg 7KB
ubbcode
bb_bold.gif 259B
bb_url.gif 375B
bb_flash.gif 381B
bb_quote.gif 363B
bb_italicize.gif 250B
bb_code.gif 277B
bb_image.gif 296B
bb_wma.gif 736B
bb_underline.gif 261B
bb_center.gif 256B
Thumbs.db 25KB
bb_wmv.gif 761B
bb_list.gif 646B
bb_email.gif 365B
Head.Fix 54B
a10.jpg 7KB
bg1.gif 47B
a4.jpg 6KB
b2.jpg 7KB
b15.jpg 8KB
b14.jpg 7KB
b10.jpg 7KB
a2.jpg 5KB
a3.jpg 8KB
b6.jpg 8KB
a13.jpg 7KB
b7.jpg 8KB
a12.jpg 7KB
a5.jpg 7KB
b1.jpg 7KB
modifylogin.asp 1KB
user_check.asp 609B
css.css 740B
MessageCheck.asp 560B
reply.asp 2KB
Function.asp 6KB
message_save.asp 2KB
ubbcode.asp 11KB
modify_save.asp 975B
copy.asp 1KB
head.asp 8KB
ViewPass.asp 2KB
user_logout.asp 71B
userlogin.asp 1KB
conn.asp 257B
index.asp 17KB
GetCode.asp 1KB
共 86 条
- 1
资源评论
lyanzhong
- 粉丝: 12
- 资源: 4
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功