當前位置:遊戲中心平台 - 單機遊戲攻略 - 誰可以提供個留言本?發送到郵箱的那種。ASP

誰可以提供個留言本?發送到郵箱的那種。ASP

<%

dim conn,rs,ps,PostIntervalTime,IpLists,LoginPassWord,OnlyShowReplay

LoginPassWord = "51windows.net" '管理密碼,請設置復雜的密碼

ps = 20 '每頁留言數

PostIntervalTime = 5*60 '同壹個IP多長時間可以留壹次言,單位是秒,5分鐘可以用5*60表示,不限制請設置為0

OnlyShowReplay = 1 '留言是否有回復再顯示,0為留言後立刻顯示在留言列表中,1為需要回復後才顯示在列表中。置頂的留言不受限制

IpLists = "192.168.|"

'禁止留言的IP,例如: "127.0.|192.168.0.1"

%><html>

<head>

<meta /whois/?ip=<% = rs("ip") %>"><% = rs("ip") %></a></td>

</tr>

<tr>

<td>回 復:</td>

<td><textarea rows="4" class="input" name="reply" cols="48" style="overflow:auto;width:100%;"><% = server.htmlencode(rs("reply")) %></textarea><div align="right"><input type="checkbox" name="isTop" id="isTop<% = rs("ID") %>" value="1"<%if Cstr(rs("IsTop"))="1" then%> checked<%end if%>><label for="isTop<% = rs("ID") %>">置頂留言</label><input type="submit" value="回 復"> <input type="button" onclick="if(confirm('確定刪除嗎?')){document.HwForm<% = rs("ID") %>.act.value='del';document.HwForm<% = rs("ID") %>.submit();}" style="color:red;" value="刪 除"></div></td>

</tr>

</form>

<%else%>

<tr>

<td nowrap>留言內容:</td>

<td><% = replace(server.htmlencode(rs("content")),vbnewline,"<br>") %></td>

</tr>

<%if len(rs("reply")) > 0 then%>

<tr>

<td>回 復:</td>

<td><% = replace(server.htmlencode(rs("reply")),vbnewline,"<br>") %></td>

</tr>

<%end if%>

<%end if%>

</table>

<%

i=i+1

if i>=MaxPerPage then exit do

rs.movenext

loop

end sub

end if

%>

</td>

</tr>

<tr>

<td width="100%" height="24" align="right" id="bottompage"><%showpages()%></td>

</tr>

<tr>

<td width="100%"><% logintable()%></td>

</tr>

</table>

</div>

<%

conn.close

set conn = nothing

Function NoJapn(byVal iStr)

if isnull(iStr) or isEmpty(iStr) then

NoJapn=""

Exit function

end if

dim F

F=array(chr(-23116),chr(-23124),chr(-23122),chr(-23120),chr(-23118),chr(-23114),chr(-23112),chr(-23110),chr(-23099),chr(-23097),chr(-23095),chr(-23075),chr(-23079),chr(-23081),chr(-23085),chr(-23087),chr(-23052),chr(-23076),chr(-23078),chr(-23082),chr(-23084),chr(-23088),chr(-23102),chr(-23104),chr(-23106),chr(-23108))

NoJapn=iStr

for i=0 to 25

NoJapn=replace(NoJapn,F(i),"")

next

End Function

function fixsql(str)

dim newstr

newstr = str

if isnull(newstr) or len(newstr) = 0 then

fixsql = newstr

exit function

end if

newstr = Replace(newstr,"'","''")

fixsql = newstr

end function

function isForbid(sip)

dim Iplist,Iparr,Ipi

Iplist = "|"& IpLists &"|"

Iparr = split(Iplist,"|")

for Ipi = 0 to ubound(Iparr)

if len(Iparr(Ipi)) > 0 and instr("|" & sip,"|" & Iparr(Ipi)) > 0 then

isForbid = true

exit function

end if

next

isForbid = false

end function

sub showpages()

pageurl = Request.ServerVariables("SCRIPT_NAME") & "?"

%>

<span id="PageZone"><%

if len(totalput) = 0 then

totalput = 0

end if

if totalpages<2 then

if int(totalpages) > 0 then

response.write "*** "&totalput&" 條留言 "

end if

else

dim Page_First,Page_Previous,Page_Next,Page_Last

Page_First = "首頁"

Page_Previous = "前頁"

Page_Next = "後頁"

Page_Last = "尾頁"

%>

>>

<%if int(currentPage) = 1 Then%>

<span class="PageDisabled"><% = Page_First %></span>

<span class="PageDisabled" id="__PrevLink"><% = Page_Previous %></span>

<a href="<%=pageurl%>Page=<%=currentPage+1%>" id="__NextLink"><% = Page_Next %></a>

<a href="<%=pageurl%>Page=<%=totalpages%>"><% = Page_Last %></a>

<%elseif int(currentPage) = int(totalpages) Then%>

<a href="<%=pageurl%>"><% = Page_First %></a>

<a href="<%=pageurl%>Page=<%=currentPage-1%>" id="__PrevLink"><% = Page_Previous %></a>

<span class="PageDisabled" id="__NextLink"><% = Page_Next %></span>

<span class="PageDisabled"><% = Page_Last %></span>

<%else%>

<a href="<%=pageurl%>"><% = Page_First %></a>

<a href="<%=pageurl%>Page=<%=currentPage-1%>" id="__PrevLink"><% = Page_Previous %></a>

<a href="<%=pageurl%>Page=<%=currentPage+1%>" id="__NextLink"><% = Page_Next %></a>

<a href="<%=pageurl%>Page=<%=totalpages%>"><% = Page_Last %></a>

<%end if%>

頁次:<span class="PageNote"><%=currentPage%></span>/<%=totalpages%> 頁 轉到 <span id=divpage></span> 頁 *** <span class="PageNote"><%=totalput%></span>個留言

<SCRIPT LANGUAGE="JavaScript">var selected="";var arr = new Array(<%=totalpages%>);for (var i=1; i<<%=totalpages+1%>; i++){if (i==<%=currentPage%>){selected="selected";}else{selected="";}arr[i] = "<OPTION value='"+i+"' "+selected+">" + i + "</OPTION>";}document.getElementById("divpage").innerHTML = "<SELECT tabindex='1' class='hwPageSelect' onChange='javascript:location.href=\"<%=pageurl%>Page=\"+this.options[selectedIndex].value'>" + arr.join() + "</SELECT>";</SCRIPT>

<%end if%></span><%

end sub

function logintable()

%>

<table width="100%" border="0" cellspacing="0" cellpadding="0">

<tr>

<form method="POST" name="login" action="<% = Request.ServerVariables("SCRIPT_NAME") %>">

<td width="100%">

<%if session("islogin") = LoginPassWord then%>

<p align="center"><a href="?action=loginout">退出管理</a></p>

<%elseif request("action") = "login" then%>

<input type="hidden" name="act" value="login">

<p align="center">請輸入密碼:<input type="password" class="input" name="pws"size="20"> <input type="submit" value="登陸"> <a href="?">取消</a></p>

<%else%>

<p align="center"><a href="?action=login#bottom">管理</a></p>

<%end if%>

</td>

</form>

</tr>

</table>

<%end function%>

<a name="bottom" />

</body>

</html>

  • 上一篇:hpcq45
  • 下一篇:sony攝影機哪個型號好
  • copyright 2024遊戲中心平台