📄 mymodify.asp
字号:
<!--#include file="conn.asp"-->
<!-- #include file="inc/const.asp" -->
<!--#include file="inc/chkinput.asp"-->
<%
'=========================================================
' File: mymodify.asp
' Version:5.0
' Date: 2002-9-11
' Script Written by satan
'=========================================================
' Copyright (C) 2001,2002 AspSky.Net. All rights reserved.
' Web: http://www.aspsky.net,http://www.dvbbs.net
' Email: info@aspsky.net,eway@aspsky.net
'=========================================================
response.buffer=true
stats="修改基本资料"
dim sex
dim showre
dim face,width,height
dim birthday
dim usercookies
call nav()
if Cint(GroupSetting(16))=0 then
Errmsg=Errmsg+"<br>"+"<li>您没有在本论坛修改资料的权限,请<a href=login.asp>登陆</a>或者同管理员联系。"
founderr=true
end if
if not founduser then
Errmsg=Errmsg+"<br>"+"<li>您还没有登陆,请登陆后进行修改。"
founderr=true
end if
if founderr then
errmsg=errmsg+"<br>"+"<li>您没有<a href=login.asp target=_blank>登录</a>。"
call head_var(2,0,"","")
call dvbbs_error()
else
call head_var(0,0,membername & "的控制面板","usermanager.asp")
if request("action")="updat" then
call update()
if founderr then
call dvbbs_error()
else
sucmsg="<li>更改资料成功!"
call dvbbs_suc()
end if
else
call userinfo()
if founderr then call dvbbs_error()
end if
end if
call activeonline()
call footer()
sub userinfo()
dim CanUseTitle,CanUseTitle1,CanUseTitle2
CanUseTitle=false
CanUseTitle1=false
CanUseTitle2=false
set rs=server.createobject("adodb.recordset")
sql="Select * from [User] where userid="&userid
rs.open sql,conn,1,1
if rs.eof and rs.bof then
errmsg=errmsg+"<br>"+"<li>该用户名不存在。"
founderr=true
exit sub
else
if Cint(Forum_Setting(6))=1 then
CanUseTitle=true
end if
if CanUseTitle and Cint(forum_setting(60))>0 and rs("article")>Cint(forum_setting(60)) then
CanUseTitle1=true
elseif CanUseTitle and Cint(forum_setting(60))=0 then
CanUseTitle1=true
else
CanUseTitle1=false
end if
if CanUseTitle and Cint(forum_setting(61))>0 and DateDiff("d",rs("AddDate"),Now())>Cint(forum_setting(61)) then
CanUseTitle2=true
elseif CanUseTitle and Cint(forum_setting(61))=0 then
CanUseTitle2=true
else
CanUseTitle2=false
end if
if CanUseTitle and Cint(forum_setting(62))=1 then
if CanUseTitle1 and CanUseTitle2 then
CanUseTitle=true
else
CanUseTitle=false
end if
elseif CanUseTitle and (CanUseTitle1 or CanUseTitle2) then
CanUseTitle=true
else
CanUseTitle=false
end if
%>
<table cellpadding=3 cellspacing=1 align=center class=tableborder1>
<tr>
<th width=14% height=25 id=tabletitlelink><a href=usermanager.asp>控制面板首页</a></th>
<th width=14% id=tabletitlelink><a href=mymodify.asp>基本资料修改</a></th>
<th width=14% id=tabletitlelink><a href=modifypsw.asp>用户密码修改</a></th>
<th width=14% id=tabletitlelink><a href=modifyadd.asp>联系资料修改</a></th>
<th width=14% id=tabletitlelink><a href=usersms.asp>用户短信服务</a></th>
<th width=14% id=tabletitlelink><a href=friendlist.asp>编辑好友列表</a></th>
<th width=14% id=tabletitlelink><a href=favlist.asp>用户收藏管理</a></th>
</tr>
</table>
<form action="mymodify.asp?action=updat&username=<%=htmlencode(membername)%>" method=POST name="theForm">
<table cellpadding=3 cellspacing=1 border=0 align=center class=tableborder1>
<tr>
<th colspan="2" width="100%">基本设置选项
</th>
</tr>
<%if CanUseTitle then%>
<tr>
<td width="40%" class=tablebody1><B>头 衔</B>:</td>
<td width="60%" class=tablebody1> <input type="text" name="title" value="<%if trim(rs("title"))<>"" then%><%=htmlencode(RS("title"))%><%end if%>" size=15 maxlength=13> </td>
</tr>
<%end if%>
<tr>
<td width="40%" class=tablebody1><B>性 别</B>:<BR>请选择您的性别</td>
<td width="60%" class=tablebody1><input type="radio" value="1"<%if rs("sex")=1 then%> checked <%end if%>name="Sex">酷哥
<input type="radio" name="Sex"<%if rs("sex")=0 then%> checked <%end if%> value="0">靓妹</td>
</td>
</tr>
<tr>
<td width="40%" class=tablebody1><B>生 日</B><BR>如不想填写,请全部留空</td>
<td width="60%" class=tablebody1>
<select name=birthyear>
<option value=""></option>
<%for i=1901 to 2000%>
<option value="<%=i%>" <%if not isnull(rs("birthday")) and isdate(rs("birthday")) then%><%if cint(year(rs("birthday")))=cint(i) then response.write "selected"%><%end if%>><%=i%></option>
<%next%>
</select>
年
<select name=birthmonth>
<option value=""></option>
<%for i=1 to 12%>
<option value="<%=i%>" <%if not isnull(rs("birthday")) and isdate(rs("birthday")) then%><%if cint(month(rs("birthday")))=cint(i) then response.write "selected"%><%end if%>><%=i%></option>
<%next%>
</select>
月
<select name=birthday>
<option value=""></option>
<%for i=1 to 31%>
<option value="<%=i%>" <%if not isnull(rs("birthday")) and isdate(rs("birthday")) then%><%if cint(day(rs("birthday")))=cint(i) then response.write "selected"%><%end if%>><%=i%></option>
<%next%>
</select>
日</font>
</td>
</tr>
<tr>
<td width="40%" valign=top class=tablebody1><B>头 像</B>:<BR>
您可以选择一个个性图片,当你发表时将显示在您的名字下方。<BR>
<%if (Cint(forum_setting(54))>0 and rs("article")>Cint(forum_setting(54))) or Cint(forum_setting(54))=0 then%>
如果你填写了下面的自定义头像部分,那么你的头像以自定义的为准。否则,请你留空自定义头像的所有栏目!<BR>
<B>关于自定义头像</B>:<BR>
你也可以在这里给出你自定义头像的 URL 地址,头像的高度和宽度(像素)。 如果不想要自定义头像,请将相应栏目栏目全部留空!
<%end if%>
</td>
<td width="60%" class=tablebody1>
<table border="0" cellpadding="0" cellspacing="1" width="98%" >
<tr>
<td width="*" class=tablebody1>论坛头像选择
<select name=face style="font-family:arial" size=1 onChange="document.images['face'].src=options[selectedIndex].value; parent.document.forms[0].myface.value=options[selectedIndex].value">
<%
dim userregface
for i=0 to Forum_userfaceNum
userregface=Forum_info(11)&Forum_userface(i)
if trim(lcase(rs("face"))) = trim(lcase(userregface)) then
%>
<option value='<%=Forum_info(11)&Forum_userface(i)%>' selected><%=Forum_userface(i)%></option>
<% else %>
<option value='<%=Forum_info(11)&Forum_userface(i)%>'><%=Forum_userface(i)%></option>
<%
end if
next
%>
</select><a href="allface.asp" target="_blank" title="头像预览列表">[<font color=red>头像预览</font>]</a></td>
<td width="180" rowspan="2" valign=top align=center>
<img id=face src="<%=rs("face")%>" width=<%=rs("width")%> height=<%=rs("height")%>>
</td>
</tr>
<tr>
<td width="*" class=tablebody1>
<%if (Cint(forum_setting(54))>0 and rs("article")>Cint(forum_setting(54))) or Cint(forum_setting(54))=0 then%>
<% if Cint(Forum_Setting(7))=1 then %>
<iframe name="ad" frameborder=0 width=250 height=26 scrolling=no src=reg_upload.asp></iframe>
<% end if %>
<br>自定义头像地址:<input type="TEXT" name="myface" size=30 maxlength=100 value=<%=rs("face")%>>
<br>宽 度:<input type="TEXT" name="width" size=3 maxlength=3 value=<%=rs("width")%>>0---<%=forum_setting(57)%>的整数
<br>高 度:<input type="TEXT" name="height" size=3 maxlength=3 value=<%=rs("height")%>>0---<%=forum_setting(57)%>的整数
<br>
<%END IF%>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="40%" class=tablebody1><B>个人照片</B>:<BR>如果您有照片在网上,请输入网页地址。此项可选</td>
<td width="60%" class=tablebody1>
<input type="TEXT" name="userphoto" value="<%if trim(rs("userphoto"))<>"" then%><%=htmlencode(rs("userphoto"))%><%end if%>" size=30 maxlength=100>
</td>
</tr>
<%if cint(Forum_Setting(32))=1 then%>
<tr>
<td width="40%" class=tablebody1><B>门 派</B>:<BR>如果您有兴趣,可加入以下门派</td>
<td width="60%" class=tablebody1>
<select name=groupname>
<%
dim grs
set grs=conn.execute("select * from GroupName")
if grs.eof and grs.bof then
%>
<option value="无门无派">无门无派</option>
<%else%>
<%do while not grs.eof%>
<option value="<%=grs("Groupname")%>" <% if instr(trim(rs("UserGroup")),trim(grs("Groupname"))) then%>selected<% end if%>><%=grs("GroupName")%></option>
<%
grs.movenext
loop
%>
<%end if%>
</select>
<%set grs=nothing%>
</td>
</tr>
<%end if%>
<%if Cint(forum_setting(42))=1 then%>
<tr>
<td valign=top width="40%" class=tablebody1><B>签 名</B>:<BR>不能超过 250 个字符
<br>
文字将出现在您发表的文章的结尾处。</td>
<td width="60%" class=tablebody1>
<textarea name="Signature" rows=5 cols=60 wrap=PHYSICAL><%if rs("sign")<>"" then%>
<%
dim signtrue
signtrue=replace(rs("sign"),"<BR>",chr(13))
signtrue=replace(signtrue," "," ")
%><%=signtrue%><%end if%></textarea>
</td>
</tr>
<%end if%>
<tr>
<th colspan="2" width="100%">其他选项
</th>
</tr>
<tr>
<td width="40%" class=tablebody1><B>有回帖时是否提示您</B>:<BR>当您的帖子有人回复后有信息通知您</td>
<td width="60%" class=tablebody1>
<input type="radio" name="showRe" value="1" <% if rs("showRe") then response.write "checked" %> >
提示我
<input type="radio" name="showRe" value="0" <% if not rs("showRe") then response.write "checked" %> >
不提示
</td>
</tr>
<tr>
<td width="40%" class=tablebody1><B>选择Cookie的保留时间</B>:</td>
<td width="60%" class=tablebody1>
<input type="radio" name="usercookies" value="1" <% if request.cookies("aspsky")("usercookies")=1 then response.write "checked" %> >
<font color=red>1天</font>
<input type="radio" name="usercookies" value="2" <% if request.cookies("aspsky")("usercookies")=2 then response.write "checked" %> >
1个月
<input type="radio" name="usercookies" value="3" <% if request.cookies("aspsky")("usercookies")=3 then response.write "checked" %>>
1年
<input type="radio" name="usercookies" value="0" <% if request.cookies("aspsky")("usercookies")=0 then response.write "checked" %>>
不保留 </td>
</tr>
<%
dim usersetting,setuserinfo,setusertrue
if rs("usersetting")<>"" then
usersetting=split(rs("usersetting"),"|||")
if ubound(usersetting)=1 then
if isnumeric(usersetting(0)) then setuserinfo=usersetting(0) else setuserinfo=1
if isnumeric(usersetting(1)) then setusertrue=usersetting(1) else setusertrue=0
else
setuserinfo=1
setusertrue=0
end if
else
setuserinfo=1
setusertrue=0
end if
%>
<tr>
<td width=40% class=tablebody1><B>是否开放您的基本资料</B>:<BR>开放后别人可以看到您的性别、Email、QQ等信息</td> <td width=60% class=tablebody1>
<input type=radio name=setuserinfo value=1 <%if setuserinfo=1 then%>checked<%end if%>>
开放 <input type=radio name=setuserinfo value=0 <%if setuserinfo=0 then%>checked<%end if%>>
不开放 </td>
</tr>
<tr>
<td width=40% class=tablebody1><B>是否开放您的真实资料</B>:<BR>开放后别人可以看到您的真实姓名、联系方式等信息</font></td> <td width=60% class=tablebody1>
<input type=radio name=setusertrue value=1 <%if setusertrue=1 then%>checked<%end if%>>
开放 <input type=radio name=setusertrue value=0 <%if setusertrue=0 then%>checked<%end if%>>
不开放 </td>
</tr>
<%
dim userinfo
dim realname,character,personal,country,province,city,shengxiao,blood,belief,occupation,marital, education,college,userphone,address
if rs("userinfo")<>"" then
userinfo=split(rs("userinfo"),"|||")
if ubound(userinfo)=14 then
realname=userinfo(0)
character=userinfo(1)
personal=userinfo(2)
country=userinfo(3)
province=userinfo(4)
city=userinfo(5)
shengxiao=userinfo(6)
blood=userinfo(7)
belief=userinfo(8)
occupation=userinfo(9)
marital=userinfo(10)
education=userinfo(11)
college=userinfo(12)
userphone=userinfo(13)
address=userinfo(14)
else
realname=""
character=""
personal=""
country=""
province=""
city=""
shengxiao=""
blood=""
belief=""
occupation=""
marital=""
education=""
college=""
userphone=""
address=""
end if
else
realname=""
character=""
personal=""
country=""
province=""
city=""
shengxiao=""
blood=""
belief=""
occupation=""
marital=""
education=""
college=""
userphone=""
address=""
end if
%>
<tr>
<th height=25 align=left valign=middle colspan=2> 个人真实信息(以下内容建议填写)</th>
</tr>
<tr>
<td valign=top width=40% class=tablebody1> <b>真实姓名:</b>
<input type=text name=realname size=18 value="<%=realname%>">
</td>
<td height=71 align=left valign=top class=tablebody1 rowspan=14 width=60% >
<table width=100% border=0 cellspacing=0 cellpadding=5>
<tr>
<td class=tablebody1><b>性 格: </b><br>
<% dim KidneyType,theKidney
KidneyType="多重性格,乐天达观,成熟稳重,幼稚调皮,温柔体贴,活泼可爱,普普通通,内向害羞,外向开朗,心地善良,聪明伶俐,善解人意,风趣幽默,思想开放,积极进取,小心谨慎,郁郁寡欢,正义正直,悲观失意,好吃懒做,处事洒脱,疑神疑鬼,患得患失,异想天开,多愁善感,淡泊名利,见利忘义,瞻前顾后,循规蹈矩,热心助人,快言快语,少言寡语,爱管闲事,追求刺激,豪放不羁,狡猾多变,贪小便宜,见异思迁,情绪多变,水性扬花,重色轻友,胆小怕事,积极负责,勇敢正义,聪明好学,实事求是,务实实际,老实巴交,圆滑老练,脾气暴躁,慢条斯理,诚实坦白,婆婆妈妈,急性子"
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -