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

📄 user_search.asp

📁 小说站源代码文件
💻 ASP
字号:
<%
dim UserID,UserName
UserID=CheckSql(request.cookies("CnEndWeb_User")("log_UserID"))
UserName=CheckSql(request.cookies("CnEndWeb_User")("log_UserName"))
If UserName="" or UserID="" or IsNull(UserID) Then
	Response.Write ("<script>alert(' CnEndWeb(终点)提醒: \n\n 可能您还没有登陆或者登陆超时 \n\n 如果您没有成为会员请先进行会员注册 \n\n 如果您已经是注册会员请重新登陆 ');location.href='user_log.asp?info=in';</script>")
	Response.End
End If
set rsu=server.createobject("adodb.recordset")
sql="select ID,Name,LockUser,GOGXuser from Userinfo where ID="&UserID&""
rsu.open sql,conn,1,1
if rsu.eof and rsu.bof then
	Response.Write ("<script>alert(' CnEndWeb(终点)提醒: \n\n 用户不存在。');history.back();</script>")
	Response.end
End If
if rsu("LockUser")=1 then
	Response.Write ("<script>alert(' CnEndWeb(终点)提醒: \n\n 用户被锁定。');history.back();</script>")
	Response.end
End If
GOGXuser=rsu("GOGXuser")
UserID=rsu("ID")
UserName=rsu("Name")
rsu.close
set rsu=nothing

nickname=CheckSql(request("nickname"))
if nickname="" then
	response.write "<script language=javascript>alert('查询内容不能为空!');history.back(-1);</script>"
	response.end
end if

Const MaxPerPage=20
If Request("page")<>"" then
    CurrentPage=Cint(Request("Page"))
Else
    CurrentPage=1
End if                 
set rs=server.createobject("adodb.recordset")
sql="select * from Userinfo where name = '"&nickname&"' ORDER BY ID desc"
'MySQL需要如下语句
conn.CursorLocation=3
rs.open sql,conn,1,1
if rs.eof and rs.bof then
	Response.Write ("<script>alert('   没有相关内容!\n\n 可能用户不存在,请查询后输入。');history.back();</script>")
	Response.end
else
%>
<script language="JavaScript">
<!--
function views(id)
{
	var filename=""+id;
	window.open(filename,"显示窗口","toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=yes,width=580,height=420");
}
//-->
</script>
<table cellspacing="1" cellpadding="4" width="100%" bgcolor="#ffffff" border="0">
	<tr bgcolor="#588fc7">
		<td colspan="4" class="head"><font color="#FFFFFF">搜索结果 </font></td>
	</tr>
<%
   Rs.PageSize=MaxPerPage
   Allpage=Rs.PageCount
   If Currentpage>Allpage Then Currentpage=1
   Num=Rs.RecordCount
   Rs.MoveFirst
   Rs.AbsolutePage=CurrentPage
   i=0
	Do While Not Rs.Eof%>
	<tr bgcolor="#ffffff">
		<td width="25%">昵称:</td>
		<td width="25%">
		<a href="javascript:views('user_duanxinadd.asp?custom=<%=rs("name")%>')">
		<%=rs("name")%></a>(给我发短信吧~)</td>
		<td width="25%">称谓:</td>
		<td width="25%"><%=rs("Sex")%></td>
	</tr>
	<tr bgcolor="#dfefff">
		<td width="25%">Email:</td>
		<td width="25%"><%=rs("Email")%></td>
		<td width="25%">ID号:</td>
		<td width="25%"><%=rs("ID")%></td>
	</tr>
	<tr bgcolor="#ffffff">
		<td>注册日期:</td>
		<td><%=rs("ADDDate")%></td>
		<td>登陆日期:</td>
		<td><%=rs("LoginTime")%></td>
	</tr>
	<tr bgcolor="#dfefff">
		<td>登陆次数:</td>
		<td><%=rs("LoginTimes")%></td>
		<td>等级:</td>
		<td><%=rs("UserLevel")%> 级</td>
	</tr>
	<tr bgcolor="#ffffff">
		<td>积分:</td>
		<td><%=rs("UserPoint")%></td>
		<td>权限:</td>
		<td><%if rs("IsVipUser")=0 then  response.write("注册会员") end if%> <%if rs("IsVipUser")=1 then  response.write("VIP 会员") end if%>
		<%if rs("GOauthor")=1 then  response.write("  驻站作家") end if%> <%if rs("GOGXuser")=1 then  response.write(" 作品更新员") end if%></td>
	</tr>
	<tr bgcolor="#dfefff">
		<td>日推荐数:</td>
		<td><%=rs("userVoteCount")%> 剩余:<%=rs("VoteCount")%></td>
		<td>藏书架数:</td>
		<td>总量:<%=rs("userboxnum")%> 剩余:<%=rs("boxnum")%> </td>
	</tr>
	<tr bgcolor="#ffffff">
		<td colspan="4"><hr></td>
	</tr>
	<%
      i=i+1
      If i>=MaxPerPage Then  Exit  Do
      Rs.MoveNext
   Loop
End If
Rs.Close
Set  Rs=Nothing
%>
</table>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
	<tr>
		<td> </td>
	</tr>
	<tr>
		<td height="24" align="center"><%
Response.Write ShowPage("user_search.asp?nickname="&nickname&"",CurrentPage,Num,MaxPerPage,True,True," 条纪录")
%></td>
	</tr>
</table>
<%
conn.close
set conn=nothing
%>

⌨️ 快捷键说明

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