?? add.asp
字號:
<% response.buffer=true%>
<!--#include file="conn.asp"-->
<%
'取出留言簿設定
set sd=server.createobject("adodb.recordset")
sql="select * from admin "
sd.open sql,con,1,1
if sd.eof and sd.bof then
response.write("留言簿設定出錯!")
response.end
else
'取出外觀設定
' gg=trim(sd("gg")) '公告
name=trim(sd("name")) '留言簿名稱
' page=trim(sd("page")) '每頁顯示留言條數
back=trim(sd("back")) '背景圖片
bk=trim(sd("bk")) '邊框顏色
' bt1=trim(sd("bt1")) '標題顏色1
bt2=trim(sd("bt2")) '標題顏色2
bt3=trim(sd("bt3")) '標題顏色3
' dy1=trim(sd("dy1")) '單元格顏色1
' dy2=trim(sd("dy2")) '單元格顏色2
dq=trim(sd("dq")) '表格對齊方式
ubb=trim(sd("ubb")) '是否支持ubb代碼及表情符號
nobq=trim(sd("nobq")) '是否支持表情選擇
tz=trim(sd("tz")) '是否允許郵件通知站長回復
fs=trim(sd("fs")) '是否允許將留言發送到站長信箱
jz=trim(sd("jz")) '是否禁止留言
btl=trim(sd("btl")) '取出頭部信息
dl=trim(sd("dl")) '取出尾部
end if
sd.close
set sd=nothing
'判斷是否禁止留言
if jz=1 then
%>
<script language=javascript>
{
alert("對不起此留言簿站長已禁止留言功能!");
window.location="index.asp";
}
</script>
<%
response.end
end if%>
<html>
<head>
<title><%=name%>留言簿--->發表留言</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" href="jgwy.css" type="text/css">
</head>
<style type="text/css">
</style>
<body background="img/site_bg.gif" leftmargin="0" topmargin="0">
<%
'輸出頭部信息
if btl<>"" then response.write(btl)
%>
<table width="775" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td>
<% if ubb=1 then %>
<SCRIPT language=JavaScript>
helpstat = false;
stprompt = false;
basic = true;
function thelp(swtch){
if (swtch == 1){
basic = false;
stprompt = false;
helpstat = true;
} else if (swtch == 0) {
helpstat = false;
stprompt = false;
basic = true;
} else if (swtch == 2) {
helpstat = false;
basic = false;
stprompt = true;
}
}
function AddText(NewCode) {
document.input.nl.value+=NewCode
}
function email() {
if (helpstat) {
alert("UBB EMAIL語法,可作為EMAIL的超級連接.\n\n用法 #1: [url]someone\@anywhere.com[/url] \n用法 #2: [url=\"someone\@anywhere.com\"]連接文字[/url]");
}
else if (basic) {
AddTxt="[url][/url]";
AddText(AddTxt);
}
else {
txt2=prompt("以下文字顯示于EMAIL連接上. ","");
if (txt2!=null) {
txt=prompt("連接地址.","mailto:");
if (txt!=null) {
if (txt2=="") {
AddTxt="[url]"+txt+"[/url]";
AddText(AddTxt);
} else {
AddTxt="[url=\""+txt+"\"]"+txt2+"[/url]";
AddText(AddTxt);
}
}
}
}
}
function showsize(size) {
if (helpstat) {
alert("設置文字大小. 課選擇1號到4號字體.\n\n用法: [size="+size+"]文字內容大小[/size="+size+"]");
} else if (basic) {
AddTxt="[size="+size+"][/size="+size+"]";
AddText(AddTxt);
} else {
txt=prompt("以下文字顯示的大小為 "+size,"文字");
if (txt!=null) {
AddTxt="[size="+size+"]"+txt+"[/size="+size+"]";
AddText(AddTxt);
}
}
}
function bold() {
if (helpstat) {
alert("UBB粗體于發言.\n\n用法: [b]粗體[/b]");
} else if (basic) {
AddTxt="[b][/b]";
AddText(AddTxt);
} else {
txt=prompt("以下文字將變為粗體.","文字");
if (txt!=null) {
AddTxt="[b]"+txt+"[/b]";
AddText(AddTxt);
}
}
}
function italicize() {
if (helpstat) {
alert("UBB斜體于發言.\n\n用法: [i]斜體[/i]");
} else if (basic) {
AddTxt="[i][/i]";
AddText(AddTxt);
} else {
txt=prompt("以下文字將變為斜體","文字");
if (txt!=null) {
AddTxt="[i]"+txt+"[/i]";
AddText(AddTxt);
}
}
}
function quote() {
if (helpstat){
alert("UBB引用語法,可特別表示引用別人處.\n\n用法: [quote]這里是引用[/quote]");
} else if (basic) {
AddTxt=" [quote] [/quote]";
AddText(AddTxt);
} else {
txt=prompt("以下內容將被引用","文字");
if(txt!=null) {
AddTxt=" [quote] "+txt+" [/quote]";
AddText(AddTxt);
}
}
}
function showcolor(color) {
if (helpstat) {
alert("UBB顏色設置語句,提示內的顏色都可以引用.\n\n用法: ["+color+"]這里是帶有顏色的字體[/"+color+"]");
} else if (basic) {
AddTxt="["+color+"][/"+color+"]";
AddText(AddTxt);
} else {
txt=prompt("以下文字顏色將變為 "+color,"文字");
if(txt!=null) {
AddTxt="["+color+"]"+txt+"[/"+color+"]";
AddText(AddTxt);
}
}
}
function center() {
if (helpstat) {
alert("UBB文字居中顯示.\n\n用法: [center]文字將被居中[/center]");
} else if (basic) {
AddTxt="[center][/center]";
AddText(AddTxt);
} else {
txt=prompt("以下文字將被居中","文字");
if (txt!=null) {
AddTxt="[center]"+txt+"[/center]";
AddText(AddTxt);
}
}
}
function hyperlink() {
if (helpstat) {
alert("UBB超級連接 \n放置URL作為超級連接.\n\n用法: [url]http://www.anywhere.com[/url]\n\n用法: [url=http://www.anywhere.com]連接文字[/url]");
} else if (basic) {
AddTxt="[url][/url]";
AddText(AddTxt);
} else {
txt2=prompt("以下文字顯示為URL連接.","");
if (txt2!=null) {
txt=prompt("下面URL轉化為超級連接.","http://");
if (txt!=null) {
if (txt2=="") {
AddTxt="[url]"+txt+"[/url]";
AddText(AddTxt);
} else {
AddTxt="[url=\""+txt+"\"]"+txt2+"[/url]";
AddText(AddTxt);
}
}
}
}
}
function image() {
if (helpstat){
alert("UBB插入圖片語句.\n\n用法: [img]http://www.anywhere.com/image.gif[/img]");
} else if (basic) {
AddTxt="[img][/img]";
AddText(AddTxt);
} else {
txt=prompt("要插入圖片的地址","http://");
if(txt!=null) {
AddTxt="[img]"+txt+"[/img]";
AddText(AddTxt);
}
}
}
function showcode() {
if (helpstat) {
alert("按照編號顯示.\nUsefull for posting code.\n\n用法: [code]這是編號過的文字[/code]");
} else if (basic) {
AddTxt=" [code] [/code]";
AddText(AddTxt);
} else {
txt=prompt("加入編號","");
if (txt!=null) {
AddTxt="[code]"+txt+"[/code]";
AddText(AddTxt);
}
}
}
function list() {
if (helpstat) {
alert("UBB目錄,是HTML里面的LI.\n\nUSE: [list] [*]項目一[/*] [*]項目二[/*] [*]項目三[/*] [/list]");
} else if (basic) {
AddTxt=" [list][*] [/*][*] [/*][*] [/*][/list]";
AddText(AddTxt);
} else {
txt=prompt("Type of list Enter \'A\' for alphabetical, \'1\' for numbered, Leave blank for bulleted.","");
while ((txt!="") && (txt!="A") && (txt!="a") && (txt!="1") && (txt!=null)) {
txt=prompt("錯誤! The only possible values for type of list are blank 'A' and '1'.","");
}
if (txt!=null) {
if (txt=="") {
AddTxt="[list]";
} else {
AddTxt="[list="+txt+"]";
}
txt="1";
while ((txt!="") && (txt!=null)) {
txt=prompt("List item Leave blank to end list","");
if (txt!="") {
AddTxt+="[*]"+txt+"[/*]";
}
}
AddTxt+="[/list] ";
AddText(AddTxt);
}
}
}
function underline() {
if (helpstat) {
alert("文字下劃線.\n\nUSE: [u]下劃線文字[/u]");
} else if (basic) {
AddTxt="[u][/u]";
AddText(AddTxt);
} else {
txt=prompt("文字已經下劃線.","Text");
if (txt!=null) {
AddTxt="[u]"+txt+"[/u]";
AddText(AddTxt);
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -