📄 message_new_edit2fly.asp
字号:
<!--#include file="conn.asp"-->
<%
if Session("adminopen")<>True then
Response.Write("您无权访问此页面")
Response.End()
end if
%>
<!--#include file="config.asp" -->
<%
dim action,username
action=Request("action")
id=Request("id")
' if Session("adminopen")<>True then
' Response.Redirect "login.asp"
' end if
IF Request("del")<>"" Then
Sql = "Delete From [messagebook] Where id="&Request("del")
Conn.Execute(Sql)
Response.Redirect "list_message2fly.asp"
End IF
if action="add2" then
Email2fly=trim(request("Email2fly"))
set rs=server.CreateObject("adodb.recordset")
sql="select * from [messagebook] where Email2fly='"&Email2fly&"'"
rs.open sql,conn,1,1
if not rs.eof then
response.write "<script language=javascript>"
response.write "alert('填写的用户名已经存在,请重新填写。');"
response.write "</script>"
response.write "<script language=javascript>location='javascript:history.back(1)'</script>"
Response.End
end if
rs.close
set rs=server.CreateObject("adodb.recordset")
sql="select * from [messagebook]"
rs.open sql,conn,3,2
rs.addnew
rs("Sex2fly")=trim(request("Sex2fly"))
rs("Name2fly")=trim(request("Name2fly"))
rs("No1Tel2fly")=trim(request("No1Tel2fly"))
rs("MobileTelephone2fly")=trim(request("MobileTelephone2fly"))
rs("P_Telephone2fly")=trim(request("P_Telephone2fly"))
rs("HomeTelephone2fly")=trim(request("HomeTelephone2fly"))
rs("WorkTelephone2fly")=trim(request("WorkTelephone2fly"))
rs("Whereabouts2fly")=trim(request("Whereabouts2fly"))
rs("NativePlace2fly")=trim(request("NativePlace2fly"))
rs("BirthDate2fly")=trim(request("BirthDate2fly"))
rs("idio_web2fly")=trim(request("idio_web2fly"))
rs("idio_weburl2fly")=trim(request("idio_weburl2fly"))
rs("QQmsnUC2fly")=trim(request("QQmsnUC2fly"))
rs("Email2fly")=trim(request("Email2fly"))
rs("address2fly")=trim(request("address2fly"))
rs("idio_data2fly")=trim(request("idio_data2fly"))
rs("remark2fly")=trim(request("remark2fly"))
rs("class2flynumber")=trim(request("class2flynumber"))
rs.update
id=rs("id")
rs.close
response.write "<script language=javascript>"
response.write "alert('添加成功。');"
response.write "</script>"
response.write "<script language=javascript>location='lockmessage2fly.asp?action=open&id="&id&"'</script>"
Response.End
end if
if action="add" then action="add2"
if action="edit" then
' response.write trim(request("action"))&"<br>"
' Response.End
Set rs=Server.CreateObject("ADODB.RecordSet")
sql="SELECT class.class2fly, messagebook.* FROM messagebook INNER JOIN class ON messagebook.class2flynumber=class.class2flynumber where id="&id&""
rs.open sql,conn,1,3
rs("Sex2fly")=trim(request("Sex2fly"))
rs("Name2fly")=trim(request("Name2fly"))
rs("No1Tel2fly")=trim(request("No1Tel2fly"))
rs("MobileTelephone2fly")=trim(request("MobileTelephone2fly"))
rs("P_Telephone2fly")=trim(request("P_Telephone2fly"))
rs("HomeTelephone2fly")=trim(request("HomeTelephone2fly"))
rs("WorkTelephone2fly")=trim(request("WorkTelephone2fly"))
rs("Whereabouts2fly")=trim(request("Whereabouts2fly"))
rs("NativePlace2fly")=trim(request("NativePlace2fly"))
rs("BirthDate2fly")=trim(request("BirthDate2fly"))
rs("idio_web2fly")=trim(request("idio_web2fly"))
rs("idio_weburl2fly")=trim(request("idio_weburl2fly"))
rs("QQmsnUC2fly")=trim(request("QQmsnUC2fly"))
rs("Email2fly")=trim(request("Email2fly"))
rs("address2fly")=trim(request("address2fly"))
rs("idio_data2fly")=trim(request("idio_data2fly"))
rs("remark2fly")=trim(request("remark2fly"))
rs("class2flynumber")=trim(request("class2flynumber"))
rs.Update
rs.Close
set rs=nothing
conn.close
set conn=nothing
response.write "<script language=javascript>"
response.write "alert('修改成功。');"
response.write "</script>"
response.write "<script language=javascript>location='lockmessage2fly.asp?action=open&id="&id&"'</script>"
Response.End
'Response.Redirect "admin_new_edit_user.asp?action=open&username="&username&""
end if
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>2Fly音乐联播 用户 管理程式</title>
<link href="site.css" rel="stylesheet" type="text/css">
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_goToURL() { //v3.0
var i, args=MM_goToURL.arguments; document.MM_returnValue = false;
for (i=0; i<(args.length-1); i+=2) eval(args[i]+".location='"+args[i+1]+"'");
}
//-->
</script>
</head>
<body>
<!--#include file="top2fly.asp" -->
<table width="720" border="0" align="center" cellpadding="2" cellspacing="1" bgcolor="#FFFFFF">
<tr bgcolor=7285CF>
<td bgcolor="7285CF"> <div align="left"><font color="#FFFFFF"> </font></div></td>
<td bgcolor="7285CF"> </td>
<td bgcolor="7285CF"> <font color="#FFFFFF"> </font></td>
<td bgcolor="7285CF"> <div align="left"><font color="#FFFFFF"> </font></div></td>
<td bgcolor="7285CF"> </td>
</tr>
<tr bgcolor="#FFFFFf">
<td colspan="5"> </td>
</tr>
</table>
<br>
<table width="720" border="0" align="center" cellpadding="2" cellspacing="1" bgcolor="#FFFFFF">
<%
if action="open" then
Set rs1=Server.CreateObject("ADODB.RecordSet")
sql="SELECT class.class2fly, messagebook.* FROM messagebook INNER JOIN class ON messagebook.class2flynumber=class.class2flynumber where id="&id&""
rs1.Open sql,conn,1,1
if rs1.eof then
Response.Write("document.write('<br><li><a href='http://dj.2fly.cn'>对不起对不起,您非法操作啦!!对不起!!</a></li><br><li>对不起!。</li>")
Response.End
else ' 13205519999 , zhsoft , 13205519999 ,
class2fly = rs1("class2fly")
class2flynumber = rs1("class2flynumber")
Sex2fly = rs1("Sex2fly")
Name2fly = rs1("Name2fly")
No1Tel2fly = rs1("No1Tel2fly")
MobileTelephone2fly = rs1("MobileTelephone2fly")
P_Telephone2fly = rs1("P_Telephone2fly")
HomeTelephone2fly = rs1("HomeTelephone2fly")
WorkTelephone2fly = rs1("WorkTelephone2fly")
Whereabouts2fly = rs1("Whereabouts2fly")
NativePlace2fly = rs1("NativePlace2fly")
BirthDate2fly = rs1("BirthDate2fly")
idio_web2fly = rs1("idio_web2fly")
idio_weburl2fly = rs1("idio_weburl2fly")
QQmsnUC2fly = rs1("QQmsnUC2fly")
Email2fly = rs1("Email2fly")
address2fly = rs1("address2fly")
idio_data2fly = rs1("idio_data2fly")
remark2fly = rs1("remark2fly")
password2fly = rs1("password2fly")
id = rs1("id")
end if
rs1.close
set rs1=nothing
action="edit"
end if
%>
<form action="message_new_edit2fly.asp?action=<%=action%>" method="post" name="form" >
<tr>
<td width="169" bgcolor="#E7E7E7"><div align="right"><font color="#000000">姓名:</font></div></td>
<td width="540" bgcolor="F2F2F2">
<input name="Name2fly" type="text" class="editbox2" id="Name2fly" value="<%=Name2fly%>" size="25" title="<%=Name2fly%>">
类别:<%=class2fly%> <input name="id" type="hidden" id="id" value="<%=id%>">
<%'if action="add2" then
%>
<select name="class2flynumber" id="class2flynumber">
<%
Set rs=Server.CreateObject("ADODB.Recordset")
sql="select * from [class] ORDER BY class2fly"
rs.Open sql,conn,1,3
if rs.eof and rs.bof then
response.write "<br><div align=center><font color=ff0000>目前还没有任何用户!</font></div><br>"
else
do while not rs.eof
class2fly2=rs("class2fly")
class2flynumber2=rs("class2flynumber")
%>
<option value="<%=class2flynumber2%>" <%if class2flynumber=class2flynumber2 then Response.Write("selected")%> ><%=class2fly2%></option>
<%
rs.movenext
loop
end if
rs.close
set rs=nothing%>
</select>
<%
'end if%></td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right"><font color="#000000">性别:</font> </div></td>
<td bgcolor="F2F2F2">
<input name="Sex2fly" type="text" class="editbox2" id="Sex2fly" value="<%=Sex2fly%>" size="8" title="singer"> </td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right"><font color="#000000">籍贯:</font></div></td>
<td bgcolor="F2F2F2">
<input name="NativePlace2fly" type="text" class="editbox2" id="NativePlace2fly" value="<%=NativePlace2fly%>" size="20" title="singer"></td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right"><font color="#000000">出生时间:</font></div></td>
<td bgcolor="F2F2F2">
<input name="BirthDate2fly" type="text" class="editbox2" id="BirthDate2fly" value="<%=BirthDate2fly%>" size="20" title="singer"></td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right"><font color="#000000">所在地:</font></div></td>
<td bgcolor="F2F2F2">
<input name="Whereabouts2fly" type="text" class="editbox2" id="Whereabouts2fly" value="<%=Whereabouts2fly%>" size="30"></td>
</tr>
<tr>
<td bgcolor="#E7E7E7"> </td>
<td bgcolor="F2F2F2"> </td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right">第一联系电话:</div></td>
<td bgcolor="F2F2F2">
<input name="No1Tel2fly" type="text" class="editbox2" id="No1Tel2fly" value="<%=No1Tel2fly%>" size="30">
</td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right"><font color="#000000">移动电话:</font></div></td>
<td bgcolor="F2F2F2">
<input name="MobileTelephone2fly" type="text" class="editbox2" id="MobileTelephone2fly" value="<%=MobileTelephone2fly%>" size="30">
</td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right"><font color="#000000">小灵通:</font></div></td>
<td bgcolor="F2F2F2">
<input name="P_Telephone2fly" type="text" class="editbox2" id="P_Telephone2fly" value="<%=P_Telephone2fly%>" size="30">
</td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right"><font color="#000000">住宅电话:</font></div></td>
<td bgcolor="F2F2F2">
<input name="HomeTelephone2fly" type="text" class="editbox2" id="HomeTelephone2fly" value="<%=HomeTelephone2fly%>" size="30" title="singer"></td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right"><font color="#000000">办公电话:</font></div></td>
<td bgcolor="F2F2F2">
<input name="WorkTelephone2fly" type="text" class="editbox2" id="WorkTelephone2fly" value="<%=WorkTelephone2fly%>" size="30"></td></tr>
<tr>
<td bgcolor="#E7E7E7"> </td>
<td bgcolor="F2F2F2"> </td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right">Email:</div></td>
<td bgcolor="F2F2F2">
<input name="Email2fly" type="text" class="editbox2" id="Email2fly" value="<%=Email2fly%>" size="30">
</td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right">个人网站:</div></td>
<td bgcolor="F2F2F2">
<input name="idio_web2fly" type="text" class="editbox2" id="idio_web2fly" value="<%=idio_web2fly%>" size="30">
</td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right">个人网站网址:</div></td>
<td bgcolor="F2F2F2">
<input name="idio_weburl2fly" type="text" class="editbox2" id="idio_weburl2fly" value="<%=idio_weburl2fly%>" size="30">
</td>
</tr>
<tr>
<td bgcolor="#E7E7E7"><div align="right">QQ-MSN-UC:</div></td>
<td bgcolor="F2F2F2">
<input name="QQmsnUC2fly" type="text" class="editbox2" id="QQmsnUC2fly" value="<%=QQmsnUC2fly%>" size="30">
</td>
</tr>
<tr>
<td valign="top" bgcolor="#E7E7E7"><div align="right">联系地址:</div></td>
<td bgcolor="F2F2F2">
<textarea name="address2fly" cols="45" rows="3" class="editbox2" id="address2fly"><%=address2fly%></textarea>
</td>
</tr>
<tr>
<td bgcolor="#E7E7E7"> </td>
<td bgcolor="F2F2F2"> </td>
</tr>
<tr>
<td valign="top" bgcolor="#E7E7E7"><div align="right">个人资料:</div></td>
<td bgcolor="F2F2F2">
<textarea name="idio_data2fly" cols="60" rows="8" class="editbox2" id="idio_data2fly"><%=idio_data2fly%></textarea>
</td>
</tr>
<tr>
<td valign="top" bgcolor="#E7E7E7"><div align="right">备注:</div></td>
<td bgcolor="F2F2F2">
<textarea name="remark2fly" cols="60" rows="7" class="editbox2" id="remark2fly"><%=remark2fly%></textarea>
</td>
</tr>
<tr>
<td colspan="2" bgcolor="#E7E7E7"><div align="center">
<input name="Submit" type="submit" class="bottom" value="添加修改 用户资料">
<input name="Submit1" type="reset" class="bottom" value="重新填写">
<!-- <a href="#" onClick="window.open('admin_modify.asp?username=<%=username%>','','scrollbars=no,width=300,height=200,top=200,left=300,resize=no');">【用户密码修改】</a> -->
<a href=?del=<%=id%> onclick="javascript:{if(confirm('您确定执行删除操作吗?')){return true;}return false;}">删除</a> </div>
</td>
</tr>
</form>
</table>
<div align="center">
<table width="720" height="29" border="0" cellpadding="0" cellspacing="0">
<tr>
<td height="10"></td>
</tr>
<tr>
<td height="22">
<!--#include file="food_2fly.asp" -->
</td>
</tr>
</table>
<br>
<a href="http://2fly.cn" target="_blank"><img src="img/power.gif" alt="2Fly工作室 官方网站" width="108" height="24" border="0"></a>
</div>
</body>
</html>
<%
conn.close
set conn=nothing
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -