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

📄 confirm.asp

📁 java的一个网上商店的源码,后台是Access数据库.功能还可以.界面比较简单,但是基本的功能都有.
💻 ASP
字号:
<% option explicit %>
<!-- #include file="_ccwlib/_lib.asp" -->
<%
'-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
'	功能:用户管理--浏览用户列表
'	Author: 顾志亮
'	@Language=VBscript
'	Create: 2002-10-14
'	Modify: 
'-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

Dim sql,rs,i
Dim perpage , pages , page , records , empty_msg  '---分页用变量
Dim uid  '---管理员ID
Dim keytext , strtemp

call DB_Connect(strconn)

'---验证身份----
uid=session("admID")
call IsValidUser(uid,sAdmin_Level+sUser_Level,1,"../error.htm",oConn)

'---取检索的关键字----
keytext=getForm("ctxtkeytext")

strtemp=""

if keytext<>"" then 
	strtemp= strtemp & " and (usr_name like '%" & keytext & "%' or usr_realname like '%" & keytext & "%')"
end if

strtemp= strtemp & " and usr_delflag='N' and usr_ispass='N' and usr_level=" & cint(sUser_user)

if strtemp<>"" then 
	strtemp=" where " & mid(strtemp,5)  
end if

sql="select usr_id,usr_realname from userinfo " & strtemp & " order by usr_id desc"

Set rs=Server.CreateObject("adodb.recordset")
rs.Open sql,oConn,1,1
  '-------------set page-----------
  If rs.Eof and rs.Bof Then
  		perpage=1
		pages=1
		records=0
		empty_msg=1
  Else 
  			rs.pagesize=MaxPerPage
			pages=rs.pagecount
			records=rs.recordcount
			page=Request("page")
			if page="" or page=empty then
				perpage=1
			else
				perpage=int(page)
				if perpage>pages then
					perpage=pages
				end if
			end if
			rs.absolutepage=perpage
			empty_msg=0
		'----------------------------
  End if

%>
<HTML>
<HEAD>
<title>诺基亚网络在线订购</title>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=gb2312">
<LINK REL="stylesheet" HREF="../../inc/css/pub.css" TYPE="TEXT/CSS">
<SCRIPT LANGUAGE="JavaScript" SRC="../../inc/js/ccw.js">
</SCRIPT>
</HEAD>

<BODY BGCOLOR=#ffffff TOPMARGIN=0 LEFTMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>
<!--#include file="../../inc/all_top.asp" -->

<!--#include file="../../inc/all_first_top.asp"-->
<!--#include file="../../inc/all_second_top.asp"-->

<TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH=710>
<TR>
	<TD COLSPAN=3><IMG SRC="../../images/dot.gif" WIDTH="1" HEIGHT="10" BORDER=0 ALT=""></TD>
</TR>
<TR>
	<TD WIDTH=170 ALIGN=right VALIGN=top>
	
	  <!--#include file="../../inc/default_left.asp"-->

	</TD>
	<TD WIDTH=15><IMG SRC="../../images/dot.gif" WIDTH="15" HEIGHT="1" BORDER=0 ALT=""></TD>
	<TD VALIGN=top>
	
	  <TABLE WIDTH=525 BORDER=0 CELLSPACING=0 CELLPADDING=0>
	  <TR>
	  	  <TD VALIGN="TOP"> 
            <TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0>
		  <TR>
		  	    <TD><B><FONT COLOR="#0033CC">用户管理</FONT></B><IMG SRC="../../images/arrow.gif" BORDER=0></TD>
				<TD ALIGN="right"><A HREF="javascript:this.location.reload();">刷新</A></TD>
		  </TR>
		  <TR BGCOLOR="#000000">
		        <TD COLSPAN="2"><IMG SRC="../../images/dot.gif" WIDTH="1" HEIGHT="1" BORDER=0 ALT=""></TD>
		  </TR>
		  </TABLE>
		  <FORM NAME="form3" METHOD="post" ACTION="confirm.asp">
			  <TABLE WIDTH="100%" BORDER="0" CELLSPACING="0" CELLPADDING="5" ALIGN="CENTER">
                <TR> 
				  <TD ALIGN="CENTER">查询用户: 关键字 
                    <INPUT TYPE="text" NAME="ctxtkeytext" VALUE="<%=keytext%>">
					<input type="image" src="../../images/search_gogo.gif" name="submit">
                  </TD>
				</TR>
			  </TABLE>
		  </FORM>
		  <TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=2>
		  <TR>
		        <TD><% If perpage=1 Then %>
                  首页 &lt;&lt;上一页 
                  <% Else %>
                  <A HREF="confirm.asp?page=1&ctxtkeytext=<%=server.urlencode(keytext)%>">首页</A> 
                  <A HREF="confirm.asp?page=<%=perpage-1%>&ctxtkeytext=<%=server.urlencode(keytext)%>">&lt;&lt;上一页</A> 
                  <% End if %>
                  <% If perpage=pages Then %>
                  下一页&gt;&gt; 尾页 
                  <% Else %>
                  <A HREF="confirm.asp?page=<%=perpage+1%>&ctxtkeytext=<%=server.urlencode(keytext)%>">下一页&gt;&gt;</A> 
                  <A HREF="confirm.asp?page=<%=pages%>&ctxtkeytext=<%=server.urlencode(keytext)%>">尾页</A> 
                  <% End if %></TD>
			<TD CLASS="ko" ALIGN=right>
			<FORM NAME="form1" METHOD="post" ACTION="confirm.asp" onsubmit="javascript:jumpto(document.form1.page.value,<%=pages%>);">
                    第<%=perpage%>页|共<%=pages%>页&nbsp;&nbsp; 进入第 
                  <INPUT TYPE="text" SIZE=2 NAME="page" VALUE="<%=perpage%>">
                  页<INPUT TYPE="hidden" NAME="ctxtkeytext" VALUE="<%=keytext%>">
					<INPUT TYPE="image" BORDER="0" NAME="imageField" SRC="../../images/go.gif">
				  </FORM></TD>
		  </TR>
		  </TABLE>

		    <FORM NAME="form2" METHOD="post" ACTION="setvalid.asp">
			  <TABLE WIDTH="100%" BORDER="1" CELLSPACING="0" CELLPADDING="5" ALIGN="CENTER" BORDERCOLORDARK="#FFFFFF" BORDERCOLORLIGHT="#666666">
                <TR> 
                  <TD BGCOLOR="#558bff"><FONT COLOR="#FFFFFF">需要进行确认的用户:(共<%=records%>人)</FONT></TD>
                </TR>
				<%
					if empty_msg=0 then 
				%>
                <TR> 
                  <TD> 
                    <TABLE WIDTH="100%" BORDER="0" CELLSPACING="1" CELLPADDING="3">
					<%
						i=0
						do while (not rs.eof) and (i<MaxPerPage)
					%>
                      <TR BGCOLOR="#e1e1e1"> 
                        <TD WIDTH="17%" ALIGN="CENTER"> 
                          <INPUT TYPE="checkbox" NAME="id" VALUE="<%=rs("usr_id")%>">
                        </TD>
                        <TD WIDTH="83%"><%=rs("usr_realname")%>&nbsp;</TD>
                      </TR>
                     <%
					 		rs.movenext
							i=i+1
						loop
					 %> 
                    </TABLE>
                  </TD>
                </TR>
                <TR ALIGN="CENTER"> 
                  <TD> 
                    <INPUT TYPE="submit" NAME="Submit2" VALUE="确 认">
                    <INPUT TYPE="RESET" NAME="Submit3" VALUE="取 消">
                    <INPUT TYPE="BUTTON" NAME="Submit22" VALUE="刷 新" onClick="javascript:document.location.reload();">
                  </TD>
                </TR>
				<% 
					end if 
					rs.close
					set rs=nothing
				%>
              </TABLE>
			</FORM>
			<TABLE WIDTH="100%" BORDER="0" CELLSPACING="0" CELLPADDING="5">
              <TR>
                <TD><% If perpage=1 Then %>
                  首页 &lt;&lt;上一页 
                  <% Else %>
                  <A HREF="confirm.asp?page=1&ctxtkeytext=<%=server.urlencode(keytext)%>">首页</A> 
                  <A HREF="confirm.asp?page=<%=perpage-1%>&ctxtkeytext=<%=server.urlencode(keytext)%>">&lt;&lt;上一页</A> 
                  <% End if %>
                  <% If perpage=pages Then %>
                  下一页&gt;&gt; 尾页 
                  <% Else %>
                  <A HREF="confirm.asp?page=<%=perpage+1%>&ctxtkeytext=<%=server.urlencode(keytext)%>">下一页&gt;&gt;</A> 
                  <A HREF="confirm.asp?page=<%=pages%>&ctxtkeytext=<%=server.urlencode(keytext)%>">尾页</A> 
                  <% End if %></TD>
				<TD ALIGN="RIGHT">每页:<%=maxperpage%>个 页次:<%=perpage%>/<%=pages%>页 </TD>
              </TR>
            </TABLE>
            <BR>
          <TABLE WIDTH=100% BORDER=0 CELLSPACING=0 CELLPADDING=0>
		  <TR>
                <TD BACKGROUND="../../images/gotop_bg.gif"><A HREF="#top"><IMG SRC="../../images/gotop.gif" BORDER="0"></A></TD>
              </TR>
		  </TABLE>
		</TD>
	  </TR>
	  </TABLE>

	</TD>
</TR>
</TABLE>

<!--#include file="../../inc/default_end.asp"-->

</BODY>
</HTML>
<%
call DB_DisConnect
%>

⌨️ 快捷键说明

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