?? default.aspx
字號:
return(false)
}
if(thisform.content.value==""){
alert("留言內容不能留空!")
thisform.content.focus()
return(false)
}
if(thisform.content.value.length>1000){
alert("留言內容不能超過1000字符!")
thisform.content.focus()
return(false)
}
if(thisform.email.value!=""&&thisform.email.value.indexOf('@', 0) == -1||thisform.email.value!=""&&thisform.email.value.indexOf(".") == -1){
alert("Email地址不合法!")
thisform.email.focus()
return(false)
}
if(thisform.qq.value!=""&&checkqq(thisform.qq.value) == false){
alert("騰訊QQ號碼不合法!")
thisform.qq.focus()
return(false)
}
}
self.onError=null;
currentX = currentY = 0;
whichIt = null;
lastScrollX = 0; lastScrollY = 0;
NS = (document.layers) ? 1 : 0;
IE = (document.all) ? 1: 0;
<!-- STALKER CODE -->
function heartBeat() {
if(IE) { diffY = document.body.scrollTop; diffX = document.body.scrollLeft; }
if(NS) { diffY = self.pageYOffset; diffX = self.pageXOffset; }
if(diffY != lastScrollY) {
percent = .1 * (diffY - lastScrollY);
if(percent > 0) percent = Math.ceil(percent);
else percent = Math.floor(percent);
if(IE) document.all.postcontent.style.pixelTop += percent;
if(NS) document.postcontent.top += percent;
lastScrollY = lastScrollY + percent;
}
if(diffX != lastScrollX) {
percent = .1 * (diffX - lastScrollX);
if(percent > 0) percent = Math.ceil(percent);
else percent = Math.floor(percent);
if(IE) document.all.postcontent.style.pixelLeft += percent;
if(NS) document.postcontent.left += percent;
lastScrollX = lastScrollX + percent;
}
}
<!-- /STALKER CODE -->
<!-- DRAG DROP CODE -->
function grabIt(e) {
if(IE) {
whichIt = event.srcElement;
while (whichIt.id.indexOf("postcontent") == -1) {
whichIt = whichIt.parentElement;
if (whichIt == null) { return true; }
}
whichIt.style.pixelLeft = whichIt.offsetLeft;
whichIt.style.pixelTop = whichIt.offsetTop;
currentX = (event.clientX + document.body.scrollLeft);
currentY = (event.clientY + document.body.scrollTop);
} else {
window.captureEvents(Event.MOUSEMOVE);
if(checkFocus (e.pageX,e.pageY)) {
whichIt = document.postcontent;
StalkerTouchedX = e.pageX-document.postcontent.pageX;
StalkerTouchedY = e.pageY-document.postcontent.pageY;
}
}
return true;
}
function moveIt(e) {
if (whichIt == null) { return false; }
if(IE) {
newX = (event.clientX + document.body.scrollLeft);
newY = (event.clientY + document.body.scrollTop);
distanceX = (newX - currentX); distanceY = (newY - currentY);
currentX = newX; currentY = newY;
whichIt.style.pixelLeft += distanceX;
whichIt.style.pixelTop += distanceY;
if(whichIt.style.pixelTop < document.body.scrollTop) whichIt.style.pixelTop = document.body.scrollTop;
if(whichIt.style.pixelLeft < document.body.scrollLeft) whichIt.style.pixelLeft = document.body.scrollLeft;
if(whichIt.style.pixelLeft > document.body.offsetWidth - document.body.scrollLeft - whichIt.style.pixelWidth - 20) whichIt.style.pixelLeft = document.body.offsetWidth - whichIt.style.pixelWidth - 20;
if(whichIt.style.pixelTop > document.body.offsetHeight + document.body.scrollTop - whichIt.style.pixelHeight - 5) whichIt.style.pixelTop = document.body.offsetHeight + document.body.scrollTop - whichIt.style.pixelHeight - 5;
event.returnValue = false;
} else {
whichIt.moveTo(e.pageX-StalkerTouchedX,e.pageY-StalkerTouchedY);
if(whichIt.left < 0+self.pageXOffset) whichIt.left = 0+self.pageXOffset;
if(whichIt.top < 0+self.pageYOffset) whichIt.top = 0+self.pageYOffset;
if( (whichIt.left + whichIt.clip.width) >= (window.innerWidth+self.pageXOffset-17)) whichIt.left = ((window.innerWidth+self.pageXOffset)-whichIt.clip.width)-17;
if( (whichIt.top + whichIt.clip.height) >= (window.innerHeight+self.pageYOffset-17)) whichIt.top = ((window.innerHeight+self.pageYOffset)-whichIt.clip.height)-17;
return false;
}
return false;
}
function dropIt() {
whichIt = null;
if(NS) window.releaseEvents (Event.MOUSEMOVE);
return true;
}
<!-- DRAG DROP CODE -->
if(NS) {
window.captureEvents(Event.MOUSEUP|Event.MOUSEDOWN);
window.onmousedown = grabIt;
window.onmousemove = moveIt;
window.onmouseup = dropIt;
}
if(IE) {
document.onmousedown = grabIt;
document.onmousemove = moveIt;
document.onmouseup = dropIt;
}
if(NS || IE) action = window.setInterval("heartBeat()",1);
function MM_showHideLayers() { //v3.0
var i,p,v,obj,args=MM_showHideLayers.arguments;
for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v='hide')?'hidden':v; }
obj.visibility=v; }
}
function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function displayWindow(theURL,winName,width,height,features) {
var window_width = width;
var window_height = height;
var newfeatures= features;
var window_top = (screen.height-window_height)/2;
var window_left = (screen.width-window_width)/2;
newWindow=window.open(''+ theURL + '',''+ winName + '','width=' + window_width + ',height=' + window_height + ',top=' + window_top + ',left=' + window_left + ',features=' + newfeatures + '');
newWindow.focus();
}
function MM_callJS(jsStr) { //v2.0
return eval(jsStr)
}
//由于雙擊滾屏與可拖動窗口沖突,如要啟用可拖動窗口請將以下代碼刪除
var currentpos,timer;
function initialize() { timer=setInterval("scrollwindow()",5);}
function sc(){clearInterval(timer);}
function scrollwindow() {currentpos=document.body.scrollTop;window.scroll(0,++currentpos);if (currentpos != document.body.scrollTop) sc();}
document.onmousedown=sc
document.ondblclick=initialize
//由于雙擊滾屏與可拖動窗口沖突,如要啟用可拖動窗口請將以上代碼刪除
//-->
</script>
</head>
<body topmargin="2">
<table width="100%" border="0" cellspacing="0" cellpadding="2" align="center">
<tr>
<td align="center">
<table class="gueststyleline" width="610" border="0" cellpadding="1" cellspacing="0" height="60">
<tr>
<td>
<table width="100%" border="0" cellspacing="0" cellpadding="6" class="gueststylebg" height="60">
<tr>
<td align="center" height="60" width="25%"><asp:image id="logo" runat=server/></td>
<td align="center" height="60" width="75%"><asp:AdRotator id="adshowtop" advertisementfile="adconfig/ad_top.xml" runat=server/></td>
</tr>
</table>
</td>
</tr>
</table>
<br>
<table class="gueststyleline" width="610" border="0" cellpadding="1" cellspacing="0">
<tr>
<td>
<table width="100%" border="0" cellspacing="0" cellpadding="6" class="gueststylebg">
<tr>
<td width="25%" align="center" height="32"><a href="default.aspx"><img src="Images/button/button1.gif" border="0" alt="返回首頁" align="top"></a></td>
<td width="25%" align="center" height="32"><a href="javascript:;" onClick="MM_showHideLayers('admin','','hide','postcontent','','show','setup','','hide')"><img src="Images/button/button3.gif" width="92" height="32" border="0" alt="發表留言"></a></td>
<td align="center" width="25%" height="32"><asp:hyperlink id="linkhome" imageurl="Images/button/button.gif" target="window" text="參觀主頁" runat=server/></td>
<td align="center" width="25%" height="32"><a id="goadmin" href="javascript:;" runat=server><asp:image id="setimage" width="92" height="32" runat=server/></a></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<form name="form2" runat=server>
<%If request.querystring("replyid")<>"" and session("isadmin")<>"" Then %>
<br>
<table class="gueststyleline" border="0" cellpadding="1" cellspacing="0" width="427" height="246" align="center">
<tr>
<td valign="top" >
<table width="100%" border="0" cellpadding="0" cellspacing="0" height="100%">
<tr>
<td valign="top">
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="gueststyleline" height="24">
<tr>
<td align="left" height="21"><img src="Images/icon/write.gif" width="16" height="16"><%if request.querystring("caption")<>"" then %>
[回復主題]:<%=request.querystring("caption")%>
<%else%>
[編輯回復]
<%end if%>
</td>
</tr>
</table>
<table width="100%" cellpadding="1" cellspacing="0" class="gueststylebg" height="100%">
<tr>
<td height="221" valign="top">
<div align="center"><br>
留言回復支持HTML貼圖及URL自動轉換<br>
<%if request.querystring("caption")<>"" then %>
<asp:textbox id="replytextbox" textmode="multiline" rows="10" columns="50" OnTextChanged="postreply" runat=server/>
<%
else
gettext()
%>
<asp:textbox id="modreplys" textmode="multiline" rows="10" columns="50" OnTextChanged="modreply" runat=server/>
<%end if%>
<br><br>
<asp:button id="submitreply" text="確 定" class="gueststylebg" runat=server/>
<input type="reset" name="resetreply" value="重 填" class="gueststylebg">
</div>
</td>
</tr>
</table>
</table>
</td>
</tr>
</table>
<%else%>
<table width="100%" border="0" cellpadding="2" cellspacing="0" align="center">
<tr>
<td align="center">
<%
Try
For i=0 to ds.Tables("guest").Rows.Count-1
%>
<BR>
<table class="gueststyleline" border="0" cellpadding="0" cellspacing="1" align="center" width="610">
<tr>
<td>
<table width="100%" border="0" cellpadding="6" cellspacing="0" class="gueststylebg" align="center">
<tr>
<td width="112" align="center" height="153" valign="top">
<table width="100%" border="0" cellspacing="0" cellpadding="0" height="100%" class="gueststylebg" >
<tr>
<td>
<table border="0" cellspacing="0" cellpadding="0" align="center" height="25">
<tr>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -