<!--#include file="byshop_conn.asp"-->
<!--#include file="session.asp"-->
<!--#include file="../md5.asp"-->
<%

Public Function FilterHtml(Str)
    If Trim(Str) = "" Or IsNull(Str) Then
        FilterHtml=""
    Else
    Str = Replace(Str, ">", "&gt;")
    Str = Replace(Str, "<", "&lt;")
    Str = Replace(Str, Chr(32), "&nbsp;")
    Str = Replace(Str ,Chr(9), "&nbsp;")
    Str = Replace(Str, Chr(34), "&quot;")
    Str = Replace(Str, Chr(39), "&#39;")
    Str = Replace(Str, Chr(13), "")
    Str = Replace(Str, Chr(10) & Chr(10), "</p><p>")
    Str = Replace(Str, Chr(10), "<br> ")
    FilterHtml = Str
    End If
End Function

action=request.QueryString("action")
id=request.QueryString("id")
select case action
case "save"
set rs=server.CreateObject("adodb.recordset")
rs.Open "select * from [byshop_user] where id="&id,conn,1,3
if trim(request.form("pass"))<>"" then
 rs("pass")=MD5(trim(request.form("pass")))
 end if

rs("company")=FilterHtml(trim(request.form("company")))'公司名称
rs("name")=FilterHtml(trim(request.form("name")))'联系人
rs("sex")=trim(request.form("sex"))'性别
rs("email")=FilterHtml(trim(request.form("email")))'电子邮箱
rs("tel")=FilterHtml(trim(request.form("tel")))'电话号码
rs("mobile")=FilterHtml(trim(request.form("mobile")))'手机号码
rs("fax")=FilterHtml(trim(request.form("fax")))'传真号码
rs("web")=FilterHtml(trim(request.form("web")))'公司网址
rs("usersort")=FilterHtml(trim(request.form("usersort")))'会员类型
rs("contract")=FilterHtml(trim(request.form("contract")))'联系方式
rs("contract2")=FilterHtml(trim(request.form("contract2")))'联系方式2
rs("address")=FilterHtml(trim(request.form("address")))'联系地址
rs("jyfw")=FilterHtml(trim(request.form("jyfw")))'主要业务
rs("message")=FilterHtml(trim(request.form("message")))'公司简介
rs("reglx")=trim(request.form("reglx"))

rs("tj")=int(request.form("tj"))


rs.Update
rs.Close
set rs=nothing
response.Redirect request.servervariables("http_referer")
end select
%>
 
  