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

📄 saveeditmyinfo.asp

📁 一个很好的班级同学录
💻 ASP
字号:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file="../public/conn.asp" -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
<link href="../mycss.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.style1 {color: #FF0000}
-->
</style>
</head>

<body topmargin="0" leftmargin="0">
<!--#include file="../public/top.asp" -->

<table width="760" border="1" align="center" cellpadding="4" cellspacing="2" class="font9Black">
<form method="post" action="" onsubmit="return VerifyInput();" name="myform">
    <tr>
      <td width="538" height="182" colspan="2" class="F9">
<%
  set rs1=server.createobject("adodb.recordset")
  sql1="select * from user where nickname='"&trim(request("nickname"))&"'"
  rs1.open sql1,secondconn,3,3
	   
  if not rs1.eof then
     if not rs1("username")=session("username") then
       errmsg=errmsg+"<br><li>昵称 "+trim(request("nickname"))+" 已被别人注册"
       founderr=true
     end if
  end if
  rs1.close
  set rs1=nothing
	  
  if founderr=true then
	     response.Write errmsg
	  else
         		  
        if trim(request("birthyear"))="" then
  	        birthyear=" "
	    else
	        birthyear=trim(request("birthyear"))
        end if
	  
	    if trim(request("birthmonth"))="" then
	        birthmonth=" "
	    else
	        birthmonth=trim(request("birthmonth"))
	    end if
	  
	    if trim(request("birthday"))="" then
	        birthday=" "
	    else
	        birthday=trim(request("birthday"))
	    end if
	  
	    if trim(request("mobile"))="" then
	        mobile=" "
	    else
	        mobile=trim(request("mobile"))
	    end if
	  
	    if trim(request("homeaddress"))="" then
	        homeaddress="没有填写"
	    else
	        homeaddress=trim(request("homeaddress"))
	    end if	

	    if trim(request("homepostcode"))="" then
	        homepostcode=" "
	    else
	        homepostcode=trim(request("homepostcode"))
	    end if	
	           
	    if trim(request("hometel"))="" then
	        hometel=" "
	    else
	        hometel=trim(request("hometel"))
	    end if	
	  
	    if trim(request("companyaddress"))="" then
	        companyaddress=" "
	    else
	        companyaddress=trim(request("companyaddress"))
	    end if	

	    if trim(request("companypostcode"))="" then
	        companypostcode=" "
	    else
	        companypostcode=trim(request("companypostcode"))
	    end if	
	           
	    if trim(request("companytel"))="" then
	        companytel=" "
	    else
	        companytel=trim(request("companytel"))
	    end if	

	    if trim(request("qq"))="" then
	        qq=" "
	    else
	        qq=trim(request("qq"))
	    end if	
	  	  
	    if trim(request("homepage"))="" then
	        homepage=" "
	    else
	        homepage=trim(request("homepage"))
	    end if	
	  
	    if trim(request("selfintro"))="" then
	        selfintro="我非常懒,没有留下任何资料"
	    else
	        selfintro=trim(request("selfintro"))
	    end if	

	    if trim(request("memo"))="" then
	        memo=" "
	    else
	        memo=trim(request("memo"))
	    end if			  

        set rs1=server.createobject("adodb.recordset")
        sql1="select * from user where username='"&session("username")&"'"
        rs1.open sql1,secondconn,3,3
	  
		rs1("password")=trim(request("password"))
        rs1("nickname")=trim(request("nickname"))
		rs1("birthyear")=birthyear
		rs1("birthmonth")=birthmonth
		rs1("birthday")=birthday
		rs1("mobile")=mobile
        rs1("homeaddress")=homeaddress
        rs1("homepostcode")=homepostcode  
		rs1("hometel")=hometel
		rs1("companyaddress")=companyaddress
        rs1("companypostcode")=companypostcode 
		rs1("companytel")=companytel
		rs1("qq")=qq
		rs1("homepage")=homepage
		rs1("selfintro")=selfintro
		rs1("memo")=memo
		rs1("sex")=request("sex")
		rs1("updatetime")=now()
  
        rs1.update
        rs1.close
        set rs1=nothing
		
		response.Write "恭喜恭喜,资料更新成功!"

 end if
%>	  
	  
	  </td>
    </tr>
  </form>
</table>
<!--#include file="../public/bottom.asp" -->
</body>
</html>

⌨️ 快捷键说明

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