netbook.asp

来自「这是一个网站后台管理的文件,请大家努力的下载,谢谢!」· ASP 代码 · 共 264 行

ASP
264
字号
<!--#include file="Inc/conn.asp"-->
<!--#include file="inc/Skin_css.asp"-->
<!--#include file="inc/config.asp"-->
<%If Session("UserName")="" Then
response.redirect"Server.asp"
end if%>
<%
Id=Session("UserName")
set Rst = Server.CreateObject("ADODB.recordset")
sql="select * from User where UserName='"&Id&"'"
rst.open sql,conn,1,1
%>
<!--#include file="Inc/Top.asp" -->
<!-- #include file="Head.asp" -->
<table width="760" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr> 
    <td height="5" valign="top" bgcolor="#FFFFFF"></td>
  </tr>
  <tr> 
    <td height="72" valign="top" bgcolor="#FFFFFF"><table width="746" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr> 
          <td class="tdbg_left"  width="190" height="179" valign="top" > <table width="100%" border="0" cellpadding="0" cellspacing="0">
              <tr> 
                <td height="34" class="title_left">&nbsp;&nbsp;&nbsp;<img src="Images/smallbook.jpg" width="10" height="10">&nbsp;&nbsp;Member center</td>
              </tr>
              <tr> 
                <td height="20"> <div align="center"><a href="Manage.asp">Amend member info</a></div></td>
              </tr>
              <TR> 
                <TD 
                            height=1 colspan="2" 
                            background=img/naSzarym.gif><IMG height=1 src="img/1x1_pix.gif" 
                              width=10></TD>
              </TR>
              <tr> 
                <td height="20"> <div align="center"><a href="ManagePwd.asp">Amend member password</a></div></td>
              </tr>
              <TR> 
                <TD 
                            height=1 colspan="2" 
                            background=img/naSzarym.gif><IMG height=1 src="img/1x1_pix.gif" 
                              width=10></TD>
              </TR>
              <tr> 
                <td height="20"> <div align="center"><a href="E_shop.asp">Order form search</a></div></td>
              </tr>
              <TR> 
                <TD 
                            height=1 colspan="2" 
                            background=img/naSzarym.gif><IMG height=1 src="img/1x1_pix.gif" 
                              width=10></TD>
              </TR>
              <tr> 
                <td height="20"> <div align="center"><a href="NetBook.asp">Feedback</a></div></td>
              </tr>
              <TR> 
                <TD 
                            height=1 colspan="2" 
                            background=img/naSzarym.gif><IMG height=1 src="img/1x1_pix.gif" 
                              width=10></TD>
              </TR>
              <tr> 
                <td height="20"> <div align="center"><a href="UserLogout.asp">Exit member center</a></div></td>
              </tr>
              <TR> 
                <TD 
                            height=1 colspan="2" 
                            background=img/naSzarym.gif><IMG height=1 src="img/1x1_pix.gif" 
                              width=10></TD>
              </TR>
            </table></td>
          <td width="6"></td>
          <td valign="top"><table Class=border width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
              <tr> 
                <td height="206" valign="top"> <table width="100%" border="0" cellspacing="0" cellpadding="0">
                    <tr> 
                      <td class="
title_right" height="32">&nbsp;&nbsp;&nbsp;<img src="Images/smallbook.jpg" width="10" height="10">&nbsp;&nbsp;Member center
                        </td>
                    </tr>
                  </table>
                  <table width="90%" border="0" align="center" cellpadding="0" cellspacing="0">            <TR> 
              <TD><table width="100%" border="0" cellspacing="0" cellpadding="0">
                  <tr> 
                    <td height="10"></td>
                  </tr>
                </table>
                <table width="90%" border="0" align="center" cellpadding="0" cellspacing="0">
                  <tr> 
                    <td><div align="center"><img src="img/newsico.gif" width="12" height="13">&nbsp;&nbsp;<b><%=Session("UserName")%></b>Message prefecture</div></td>
                  </tr>
                  <tr> 
                    <td>&nbsp;&nbsp;&nbsp;&nbsp;<%=Session("UserName")%>,This is your special-purpose private  dense visitor book,you can leave a message for us here,we will is it in reply you this,please don is it is it watch and reply to come back to forget within 24 hours to do the best! <br>
                     If you is it do shopping to stand in me already,please reach here register the remitance after remitting money,fill in your order number,remittance time,which account number is remitted to us,so that we verify reach the situation of accounts and deliver for you in timing of your found.</td>
                  </tr>
                </table>
                <form method="post" action="SaveNetBooK.asp">
                  <input type=hidden readonly name="Name"   value="<%=Session("UserName")%>">
                  <table width="95%" border="0" align="center" cellpadding="4" cellspacing="1">
                    <tr> 
                      <td width="24%" align="right"></td>
                      <td width="76%"></td>
                    </tr>
                    <tr> 
                      <td width="24%" align="right">Username:</td>
                      <td width="76%"><font> 
                        <input type="text" readonly name="Name2" maxlength="36" value="<%if Session("UserName")="" then response.write"Haven't this username" end if%><%=Session("UserName")%>" style="background-color: #FFFFFF; border-style: solid; border-color: #FFFFFF" class="smallInput">
                        </font></td>
                    </tr>
                    <tr> 
                      <td align="right">Company name:</td>
                      <td width="76%"><font> 
                        <input type="text" name="Comane" size="30" maxlength="36" value="<%=rst("Comane")%>" style="font-size: 14px" class="smallInput">
                        </font> </td>
                    </tr>
                    <tr> 
                      <td align="right">ContactPerson:</td>
                      <td width="76%"><font> 
                        <input type="text" name="Somane" size="12" maxlength="30" value="<%=rst("Somane")%>" style="font-size: 14px" class="smallInput">
                        </font></td>
                    </tr>
                    <tr> 
                      <td align="right">Telephone:</td>
                      <td width="76%"><font> 
                        <input type="text" name="Phone" size="24" maxlength="36" value="<%=rst("Phone")%>" style="font-size: 14px" class="smallInput">
                        </font></td>
                    </tr>
                    <tr> 
                      <td align="right">FAX:</td>
                      <td width="76%"><font> 
                        <input type="text" name="Fox" size="18" maxlength="36" value="<%=rst("Fox")%>" style="font-size: 14px" class="smallInput">
                        </font></td>
                    </tr>
                    <tr> 
                      <td align="right">E-mail:</td>
                      <td width="76%"><font> 
                        <input type="text" name="Email" size="18" maxlength="36" value="<%=rst("Email")%>" style="font-size: 14px" class="smallInput">
                        </font></td>
                    </tr>
                    <tr> 
                      <td width="24%" align="right">LeaveWordTheme:</td>
                      <td width="76%"><input type="text" name="Title" size="22" maxlength="36" style="font-size: 14px; width: 320; height: 19" class="smallInput"></td>
                    </tr>
                    <tr> 
                      <td width="24%" align="right">LeaveWordContent:</td>
                      <td width="76%"><textarea rows="6" name="Content" cols="50" style="font-size: 14px" class="smallInput"></textarea> 
                      </td>
                    </tr>
                    <tr> 
                      <td width="24%" align="right"></td>
                      <td width="76%"><input type="submit" value="ReferWord"
name="cmdOk"> &nbsp; <input type="reset" value="Rewrite" name="cmdReset"> </td>
                    </tr>
                  </table>
                </form>
                <%


name=Session("UserName")
set rs=server.createobject("adodb.recordset")
sql="select * from book where name='"&name&"' or name='管理员' order by id desc"
rs.open sql,conn,1,1

dim MaxPerPage
MaxPerPage=10

'取得页数,并判断留言输入的是否数字类型的数据,如不是将以第一页显示
dim text,checkpage
text="0123456789"
Rs.PageSize=MaxPerPage
for i=1 to len(request("page"))
checkpage=instr(1,text,mid(request("page"),i,1))
if checkpage=0 then
exit for
end if
next

If checkpage<>0 then
If NOT IsEmpty(request("page")) Then
CurrentPage=Cint(request("page"))
If CurrentPage < 1 Then CurrentPage = 1
If CurrentPage > Rs.PageCount Then CurrentPage = Rs.PageCount
Else
CurrentPage= 1
End If
If not Rs.eof Then Rs.AbsolutePage = CurrentPage end if
Else
CurrentPage=1
End if

call list

'显示帖子的子程序
Sub list()%> 
<table width="90%" height="19" border="0" align="center" cellpadding="0" cellspacing="0">
<tr><td width="21%" height="18" bgcolor="#eeeeee"><img src="img/arrow.gif" width="16" height="13"><strong>Leave word list</strong></td>
<td width="79%" bgcolor="#eeeeee"> 
<%Response.write "<strong><font color='#000000'>-> All-</font>"
Response.write "amount</font>" & "<font color=#FF0000>" & Cstr(Rs.RecordCount) & "</font>" & "<font color='#000000'>bar info</font></strong>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;"
Response.write "<strong><font color='#000000'></font>" & "<font color=#FF0000>" & Cstr(CurrentPage) &  "</font>" & "<font color='#000000'>/" & Cstr(rs.pagecount) & "</font></strong>&nbsp;"
If currentpage > 1 Then
response.write "<strong><a href='NetBook.asp?&page="+cstr(1)+"'><font color='#000000'>Home</font></a><font color='#ffffff'> </font></strong>"
Response.write "<strong><a href='NetBook.asp?page="+Cstr(currentpage-1)+"'><font color='#000000'>Previous</font></a><font color='#ffffff'> </font></strong>"
Else
Response.write "<strong><font color='#000000'>Previous </font></strong>"
End if
If currentpage < Rs.PageCount Then
Response.write "<strong><a href='NetBook.asp?page="+Cstr(currentPage+1)+"'><font color='#000000'>Next</font></a><font color='#ffffff'> </font>"
Response.write "<a href='NetBook.asp?page="+Cstr(Rs.PageCount)+"'><font color='#000000'>End page</font></a></strong>&nbsp;&nbsp;"
Else
Response.write ""
Response.write "<strong><font color='#000000'>Next</font></strong>&nbsp;&nbsp;"
End if
%> </td></tr>
<tr><td height="1" colspan="2" bgcolor="#999999"></td></tr>
</table>
<%
If rs.eof and rs.bof then
  response.write ""
  response.end
End if
%> <br> <table width="90%" height="18" border="0" align="center" cellpadding="2" cellspacing="1" bgcolor="#666666">
                  <tr bgcolor="#99CCFF"> 
                    <td width="56%" height="25" align="center" bgcolor="#CCCCCC"> 
                      <p align="center"><font color="#000000"><b>Leave word motif</b></font></p></td>
                    <td width="22%" height="21" align="center" bgcolor="#CCCCCC"><font color="#000000"><b>Time</b></font></td>
                    <td width="22%" height="21" align="center" bgcolor="#CCCCCC"><font color="#000000"><b>Revert</b></font></td>
                  </tr>
<%
if not rs.eof then
i=0
do while not rs.eof
%>
                  <tr bgcolor="#99CCFF"> 
                    <td height="22" bgcolor="#FFFFFF"> <%if rs("name")="Managing person"then%>
                              『The managing person announces』 
                              <%end if%> <a href="javascript:winopen('NetBookRe.asp?id=<%=rs("id")%>&amp;name=<%=rs("name")%>')"> 
                      <%=rs("title")%></a></td>
                    <td height="1" bgcolor="#FFFFFF" align="center">&nbsp; <%=rs("time")%></td>
                    <td height="1" bgcolor="#FFFFFF" align="center">&nbsp; <%If rs("rebook")<>"" Then%> <a href="javascript:winopen('NetBookRe.asp?id=<%=rs("id")%>&amp;name=<%=rs("name")%>')">write back</a> 
                      <%else%>
                      no 
                      <%End If%> &nbsp;</td>
                  </tr>
                  <%
i=i+1
if i >= MaxPerpage then exit do
rs.movenext
loop
end if
%>
<%end sub%>
                </table>
                <br> <br> </TD>
            </TR>
                  </table></td>
              </tr>
            </table></td>
        </tr>
      </table></td>
  </tr>
</table>
<!-- #include file="Inc/Foot.asp" -->
</BODY></HTML>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?