⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 delhw.asp

📁 网络购物
💻 ASP
字号:
<%'=========================================''         凡人网络购物系统V4.0免费版'    FreeDown.Net info@freedown.net '            www.freedown.net'     版权所有·免费版仅供研究测试只用'            商业使用请购买正版''=========================================%>
<%
if session("admin_name")="" then
    response.redirect "login.asp"
end if
set rs=server.createobject("adodb.recordset")
%>
<!--#include file="conn.asp"--><head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href=../css.css rel=STYLESHEET type=text/css>
</head>

<%
if request("action")="del" then
    sql="select * from hw where hw_id="&request("hw_id")
    rs.open sql,conn,3,3
    if rs.eof then
        response.redirect "delhw.asp"
    else
    rs.delete
    rs.update
    end if
    rs.close
    response.write "货物删除成功"
    response.write "<br>"
    response.write "<a href=delhw.asp>返回</a>"
else
%>

<div align="center">
  <center>

<table width="550" border="0" cellspacing="0" cellpadding="0" bgcolor="#DBC2B0" style="border-collapse: collapse" bordercolor="#111111" >
  <tr>
    <td>
      <table width="100%" border="0" cellspacing="1" cellpadding="0" height="32" align="center">
        <tr> 
          <td bgcolor="#DBC2B0" height="21" width="140"> 
            <div align="center"><font color="#FFFFFF">商品名称</font></div>
            </td>
          <td bgcolor="#DBC2B0" height="21" width="94"> 
            <div align="center"><font color="#FFFFFF">作者 </font> </div>
          </td>
          <td bgcolor="#DBC2B0" height="21" width="51"> 
            <div align="center"><font color="#FFFFFF">会员价</font></div>
          </td>
          <td bgcolor="#DBC2B0" height="21" width="106"> 
            <div align="center"><font color="#FFFFFF">ISBN号码</font></div>
          </td>
          <td bgcolor="#DBC2B0" height="21" width="76"> 
            <div align="center"><font color="#FFFFFF">加入日期</font></div>
          </td>
          <td bgcolor="#DBC2B0" height="21" colspan="2"> 
            <div align="center"><font color="#FFFFFF">操作</font></div>
          </td>
        </tr>
        <%
  page=request.querystring("page")
  if page="" then page=1
  if not(isnumeric(page)) then page=1
  if page<1 then page=1
  page=int(page)
  
  sql="select * from hw order by hw_id DESC"
  rs.open sql,conn,3,3
  if rs.eof then
      response.write "暂且没有货物资料"
      response.end
  else
      rs.pagesize=100
      totalrec=rs.recordcount
      totalpage=rs.pagecount
      if page>totalpage then page=totalpage
      rs.absolutepage=page
      'rs.absolutepage=page
      i=0
      dim hw_id(),hw_name(),hw_cash(),hw_pic(),hw_date(),sort_id(),isbn(),hw_sn(),Nsort_ind()
      do while not rs.eof and (i<rs.pagesize)
      i=i+1
      redim preserve hw_id(i),hw_name(i),hw_cash(i),hw_pic(i),hw_date(i),sort_id(i),isbn(i),hw_sn(i),Nsort_id(i)
      hw_id(i)=rs("hw_id")
      hw_name(i)=rs("hw_name")
      hw_cash(i)=rs("hw_cash")
      hw_pic(i)=rs("hw_pic")
      hw_date(i)=rs("hw_date")
      sort_id(i)=rs("sort_id")
      isbn(i)=rs("isbn")
      hw_sn(i)=rs("hw_sn")
Nsort_id(i)=rs("Nsort_id")
      rs.movenext
      loop
  end if
  rs.close
  %>
        <%for i = 1 to ubound(hw_id)%>
        <tr bgcolor="#FFFFFF"> 
          <td height="22" width="140"><%=hw_name(i)%> </td>
          <td height="22" width="94"> 
            <div align="center"><%=hw_sn(i)%></div>
          </td>
          <td height="22" width="51"> 
            <div align="center"><%=hw_cash(i)%></div>
          </td>
          <td height="22" width="106"> 
            <div align="center"><%=isbn(i)%></div>
          </td>
          <td height="22" width="76"> 
            <div align="center"><%=hw_date(i)%></div>
          </td>
          <td height="22" width="30"> 
            <div align="center"> <a href="delhw.asp?hw_id=<%=hw_id(i)%>&action=del">删除</a></div>
          </td>
          <td height="22" width="45"> 
            <div align="center"><a href="changehw.asp?hw_id=<%=hw_id(i)%>&sort_id=<%=sort_id(i)%>&Nsort_id=<%=Nsort_id(i)%>">修改</a> 

            </div>
          </td>
        </tr>
        <%next%>
      </table>
    </td>
  </tr>
</table>
  </center>
</div>
<table border="0" width="500" cellspacing="0" height="10" align="center">
  <tr> 
    <td> 
      <p align="left">共<font color=red><%=totalpage%></font>页 第<%=page%>页 <font color=666666> 
        <%if page-1>0 then%>
        <a href="delhw.asp?page=<%=page-1%>">上一页</a> 
        <%else%>
        <font color=666666>上一页</font> 
        <%end if%>
          
        <%if page+1<=totalpage then%>
        <a href="delhw.asp?page=<%=page+1%>">下一页</a> 
        <%else%>
        <font color=666666>下一页</font> 
        <%end if%>
        </font></p>
    </td>
  </tr>
  <tr> 
    <td></td>
  </tr>
</table>
<%end if
set rs=nothing
conn.close
set conn=nothing
%>

⌨️ 快捷键说明

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