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

📄 userinfo.asp

📁 此文件为一个电子同学录
💻 ASP
字号:
<!--#include file="conn.asp"-->
<!-- #include file="inc/const.asp" -->
<!--#include file="inc/ubbcode.asp"-->
<!--#include file="inc/birthday.asp"-->
<%
'=========================================================
' File: userinfo.asp
 ' Date: 2006-04-06
' Script Written by Leibo
'=========================================================
' Copyright (C) 2002,2008 Mathren.com. All rights reserved.
' Web: http://www.hrbyydz.com
' Email: qa_90@hotmail.com
'=========================================================
dim suserid
dim abgcolor
founderr=false

if Cint(GroupSetting(2))=1 then
	Errmsg=Errmsg+"<br>"+"<li>您没有查看同学录成员资料的权限,请<a href=login.asp>登陆</a>或者同管理员联系。"
	founderr=true
end if

username=trim(checkStr(request("name")))
stats="查询"&username&"个人资料"

if founderr then
	call head()
	call head_var("错误信息","")
	call txl_error()
else
	call head()
	call head_var("","")
	if founderr then
		call txl_error()
	else
		call main()
		if founderr then call txl_error()
	end if
end if
call foot()

sub main()

if isnumeric(request("id")) then
	suserid=request("id")
else
	if username="" then
   		ErrMsg=Errmsg+"<br>"+"<li>错误的参数。"
		founderr=true
		exit sub
	end if
end if

set rs=server.createobject("adodb.recordset")
if suserid="" then
	sql="select * from [User] where realname='"&UserName&"'"
else
	sql="select * from [user] where userid="&suserid
end if
rs.open sql,conn,1,1
if err.number<>0 then 
	ErrMsg=Errmsg+"<br>"+"<li>数据库操作失败:"&err.description
	founderr=true
	exit sub
end if
if rs.eof and rs.bof then
	ErrMsg=Errmsg+"<br>"+"<li>您查询的名字不存在"
	founderr=true
	exit sub
end if
suserid=rs("userid")
usergroup=rs("usergroup")
username=rs("realname")
%>
<table width="<%=txl_body(0)%>" cellpadding="0" cellspacing="0" align="center" style="border:1px <%=txl_body(9)%> solid; border-top-width: 0px; border-right-width: 1px; border-bottom-width: 0px; border-left-width: 1px;">  
<tr> 
<td  bgcolor=<%=txl_body(10)%>><br>
<table cellpadding=3 cellspacing=1 border=0 align=center width=<%=txl_body(19)%>>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif colspan=2>&nbsp;<img src=<%=txl_info(7)%>dot02.gif border=0>&nbsp;&nbsp;<font color=<%=txl_body(20)%>>基本资料</font></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;姓名:&nbsp;&nbsp;<%=rs("realname")%></td>
<td rowspan=7 align=center><%=iimg(rs("userphoto"),"<font color=gray>没有填写照片</font>","<a href="&htmlencode(rs("userphoto"))&" target=_blank><img src="&htmlencode(rs("userphoto"))&" border=0 height=175></a>")%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;性别:&nbsp;&nbsp;<%=iif(rs("sex"),"女","男")%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;年龄:&nbsp;&nbsp;<%if rs("birthday")="" or isnull(rs("birthday")) then%><font color=gray>未填</font><%else%><%=year(now())-year(rs("birthday"))%><%end if%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;星座:&nbsp;&nbsp;<%=iimg(rs("birthday"),"<font color=gray>未填</font>",astro(rs("birthday")))%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;生日:&nbsp;&nbsp;<%=iimg(rs("birthday"),"<font color=gray>未填</font>",rs("birthday"))%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;类别:&nbsp;&nbsp;<%=rs("usergroup")%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;注册时间:&nbsp;&nbsp;<%=rs("regtime")%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif> </td>
<td align=center background=<%=txl_info(7)%>card.gif><a href=javascript:openScript('messanger.asp?action=new&touser=<%=htmlencode(rs("realname"))%>',500,400)>[给他留言]</a></td>
</tr>
</table>
<table cellpadding=3 cellspacing=1 align=center width=<%=txl_body(19)%>>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;<img src=<%=txl_info(7)%>dot02.gif border=0>&nbsp;&nbsp;<font color=<%=txl_body(20)%>>联系方式</font></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;Email:&nbsp;&nbsp;<%=iimg(rs("email"),"<font color=gray>未填</font>","<a href=mailto:"&htmlencode(rs("email"))&">"&htmlencode(rs("email"))&"</a>")%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;OICQ:&nbsp;&nbsp;<%=iimg(rs("oicq"),"<font color=gray>未填</font>",htmlencode(rs("oicq")))%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;电话:&nbsp;&nbsp;<%=iimg(rs("telephone"),"<font color=gray>未填</font>",htmlencode(rs("telephone")))%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;手机:&nbsp;&nbsp;<%=iimg(rs("mobile"),"<font color=gray>未填</font>",htmlencode(rs("mobile")))%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;个人主页:&nbsp;&nbsp;<%=iimg(rs("homepage"),"<font color=gray>未填</font>","<a href="&htmlencode(rs("homepage"))&" target=_blank>"&htmlencode(rs("homepage"))&"</a> ")%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;联系地址:&nbsp;&nbsp;<%=iimg(rs("address"),"<font color=gray>未填</font>",htmlencode(rs("address")))%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif> </td>
</tr>
</table>
<table cellpadding=3 cellspacing=1 align=center width=<%=txl_body(19)%>>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif colspan=2>&nbsp;<img src=<%=txl_info(7)%>dot02.gif border=0>&nbsp;&nbsp;<font color=<%=txl_body(20)%>>基本统计</font></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;访问次数:&nbsp;&nbsp;<%=rs("logins")%></td>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;发表留言:&nbsp;&nbsp;<%=rs("bookcount")%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;发表帖子:&nbsp;&nbsp;<%=rs("bbscount")%></td>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;上传照片:&nbsp;&nbsp;<%=rs("photocount")%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;当前资产:&nbsp;&nbsp;<%=rs("usermoney")%></td>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;当前位置:&nbsp;&nbsp;<font color=gray>离线</font></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;上次登录地址:&nbsp;&nbsp;<%=rs("lastip")%></td>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;&nbsp;&nbsp;&nbsp;上次登录时间:&nbsp;&nbsp;<%=rs("lasttime")%></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif colspan=2> </td>
</tr>
</table>
<table cellpadding=3 cellspacing=1 align=center width=<%=txl_body(19)%>>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif>&nbsp;<img src=<%=txl_info(7)%>dot02.gif border=0>&nbsp;&nbsp;<font color=<%=txl_body(20)%>>个性签名</font></td>
</tr>
<tr>
<td height=25 background=<%=txl_info(7)%>card.gif align=center style="line-height:200%">&nbsp;&nbsp;&nbsp;&nbsp;<%=iimg(rs("sign"),"<font color=gray>这家伙很懒,什么都没有留下!</font>",ubbcode(rs("sign")))%></td>
</tr>
</table><br>
</td>
</tr>
</table>
<%
end sub
%>

⌨️ 快捷键说明

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